Class InsertRowPlan

    • Constructor Detail

      • InsertRowPlan

        public InsertRowPlan()
      • InsertRowPlan

        public InsertRowPlan​(org.apache.iotdb.commons.path.PartialPath prefixPath,
                             long insertTime,
                             java.lang.String[] measurementList,
                             java.lang.String[] insertValues)
      • InsertRowPlan

        public InsertRowPlan​(org.apache.iotdb.commons.path.PartialPath prefixPath,
                             long insertTime,
                             java.lang.String[] measurementList,
                             java.nio.ByteBuffer values,
                             boolean isAligned)
                      throws QueryProcessException
        Throws:
        QueryProcessException
      • InsertRowPlan

        public InsertRowPlan​(org.apache.iotdb.commons.path.PartialPath prefixPath,
                             long insertTime,
                             java.lang.String[] measurements,
                             org.apache.iotdb.tsfile.file.metadata.enums.TSDataType[] dataTypes,
                             java.lang.String[] insertValues)
      • InsertRowPlan

        public InsertRowPlan​(org.apache.iotdb.commons.path.PartialPath prefixPath,
                             long insertTime,
                             java.lang.String[] measurements,
                             org.apache.iotdb.tsfile.file.metadata.enums.TSDataType[] dataTypes,
                             java.lang.String[] insertValues,
                             boolean isAligned)
      • InsertRowPlan

        public InsertRowPlan​(org.apache.iotdb.commons.path.PartialPath prefixPath,
                             long insertTime,
                             java.lang.String measurement,
                             org.apache.iotdb.tsfile.file.metadata.enums.TSDataType type,
                             java.lang.String insertValue)
      • InsertRowPlan

        public InsertRowPlan​(org.apache.iotdb.tsfile.write.record.TSRecord tsRecord)
                      throws org.apache.iotdb.commons.exception.IllegalPathException
        Throws:
        org.apache.iotdb.commons.exception.IllegalPathException
    • Method Detail

      • getTime

        public long getTime()
      • setTime

        public void setTime​(long time)
      • isNeedInferType

        public boolean isNeedInferType()
      • setNeedInferType

        public void setNeedInferType​(boolean inferType)
      • transferType

        public void transferType()
                          throws QueryProcessException
        if inferType is true, transfer String[] values to specific data types (Integer, Long, Float, Double, Binary)
        Throws:
        QueryProcessException
      • markFailedMeasurementInsertion

        public void markFailedMeasurementInsertion​(int index,
                                                   java.lang.Exception e)
        Description copied from class: InsertPlan
        This method is overrided in InsertRowPlan and InsertTabletPlan. After marking failed measurements, the failed values or columns would be null as well. We'd better use "measurements[index] == null" to determine if the measurement failed.
        Overrides:
        markFailedMeasurementInsertion in class InsertPlan
        Parameters:
        index - failed measurement index
      • getPaths

        public java.util.List<org.apache.iotdb.commons.path.PartialPath> getPaths()
        Specified by:
        getPaths in class PhysicalPlan
      • getValues

        public java.lang.Object[] getValues()
      • setValues

        public void setValues​(java.lang.Object[] values)
      • equals

        public boolean equals​(java.lang.Object o)
        Overrides:
        equals in class java.lang.Object
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • serializedSize

        public int serializedSize()
        Description copied from interface: SerializedSize
        Calculate size after serialization.
        Specified by:
        serializedSize in interface SerializedSize
        Returns:
        bytes number
      • serialize

        public void serialize​(java.io.DataOutputStream stream)
                       throws java.io.IOException
        Description copied from class: PhysicalPlan
        Serialize the plan into the given buffer. All necessary fields will be serialized.
        Overrides:
        serialize in class PhysicalPlan
        Throws:
        java.io.IOException
      • subSerialize

        public void subSerialize​(java.io.DataOutputStream stream)
                          throws java.io.IOException
        Throws:
        java.io.IOException
      • deserialize

        public void deserialize​(java.io.DataInputStream stream)
                         throws java.io.IOException,
                                org.apache.iotdb.commons.exception.IllegalPathException
        Overrides:
        deserialize in class PhysicalPlan
        Throws:
        java.io.IOException
        org.apache.iotdb.commons.exception.IllegalPathException
      • deserialize

        public void deserialize​(java.nio.ByteBuffer buffer)
                         throws org.apache.iotdb.commons.exception.IllegalPathException
        Description copied from class: PhysicalPlan
        Deserialize the plan from the given buffer.
        Overrides:
        deserialize in class PhysicalPlan
        Throws:
        org.apache.iotdb.commons.exception.IllegalPathException
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
      • composeTimeValuePair

        public org.apache.iotdb.tsfile.read.TimeValuePair composeTimeValuePair​(int columnIndex)
      • getPlanFromFailed

        public InsertPlan getPlanFromFailed()
        Description copied from class: InsertPlan
        Reconstruct this plan with the failed measurements.
        Overrides:
        getPlanFromFailed in class InsertPlan
        Returns:
        the plan itself, with measurements replaced with the previously failed ones.
      • recoverFromFailure

        public void recoverFromFailure()
        Description copied from class: InsertPlan
        Reset measurements from failed measurements (if any), as if no failure had ever happened.
        Overrides:
        recoverFromFailure in class InsertPlan