It is implementad as a wrapper around a raw store record handle.
| Modifier and Type | Field and Description |
|---|---|
| private static final int | |
| private long | pageno
The HeapRowLocation simply maintains a raw store record handle. |
| private int | |
| private static final int | |
| private RecordHandle |
| Access | Constructor and Description |
|---|---|
| pack-priv | |
| public | |
| private |
| Modifier and Type | Method and Description |
|---|---|
| public DataValueDescriptor | cloneValue(boolean
any streams representing the data value will
be materialized if forceMaterialization)true, the data value will be kept as a
stream if possible if falseImplements org. Clone this DataValueDescriptor. |
| public boolean | compare(int
Orderable.ORDER_OP_EQUALS means do an = comparison.
Orderable.ORDER_OP_LESSTHAN means compare this < other.
Orderable.ORDER_OP_LESSOREQUALS means compare this <= other. op, DataValueDescriptor The DataValueDescriptor to compare this one to. other, boolean True means to treat nulls as ordered values,
that is, treat SQL null as equal to null, and less
than all other values.
False means to treat nulls as unknown values,
that is, the result of any comparison with a null
is the UNKNOWN truth value. orderedNulls, boolean The return value to use if the result of the
comparison is the UNKNOWN truth value. In other
words, if orderedNulls is false, and a null is
involved in the comparison, return unknownRV.
This parameter is not used orderedNulls is true. unknownRV)Overrides org. Implements org. Compare this Orderable with a given Orderable for the purpose of qualification and sorting. |
| public int | compare(DataValueDescriptor
The Orderable to compare this one to. other)Implements org. Compare this Orderable with a given Orderable for the purpose of index positioning. |
| public boolean | equals(Object
the reference object with which to compare. ref)Overrides org. Implement value equality. |
| public int | estimateMemoryUsage()
Implements org. Estimate the memory usage in bytes of the data value and the overhead of the class. |
| public int | getLength()
Implements org. Gets the length of the data value. |
| public DataValueDescriptor | getNewNull()
Implements org. Get a new null value of the same type as this data value. |
| public Object | getObject()
Overrides org. Implements org. Gets the value in the data value descriptor as a Java Object. |
| public RecordHandle | |
| public String | getString()
Implements org. Gets the value in the data value descriptor as a String. |
| public int | getTypeFormatId()
Implements org. Return my format identifier. |
| public String | getTypeName()
Implements org. Get the SQL name of the datatype |
| public int | |
| public boolean | isNull()
Implements org. Return whether the value is null or not. |
| public void | readExternal(ObjectInput
the stream to read data from in order to restore the object in)Implements java. The object implements the readExternal method to restore its contents by calling the methods of DataInput for primitive types and readObject for objects, strings and arrays. |
| public void | readExternalFromArray(ArrayInputStream
The array stream positioned at the beginning of the
byte stream to read from. in)Overrides org. Implements org. Read the DataValueDescriptor from the stream. |
| public DataValueDescriptor | Returns: this object reset to its initial stateOverrides org. Implements org. Recycle this HeapRowLocation object. |
| public void | restoreToNull()
Implements org. Restore this object to its (SQL)null value. |
| pack-priv void | |
| protected void | setFrom(DataValueDescriptor
The DataValueDescriptor that holds the value to
which we want to set this DataValueDescriptor's value. theValue)Overrides org. Set the value of this DataValueDescriptor based on the value of the specified DataValueDescriptor. |
| public void | setValue(RowLocation
Contains the boolean value to set this RefDataValue
to. Null means set this RefDataValue to null. rowLocation)Implements org. Set the value of this RefDataValue. |
| public void | setValueFromResultSet(ResultSet
The specified ResultSet. resultSet, int The 1-based column # into the resultSet. colNumber, boolean Whether or not the column is nullable
(No need to call wasNull() if not) isNullable)Implements org. Set the value based on the value for the specified DataValueDescriptor from the specified ResultSet. |
| public String | |
| public void | writeExternal(ObjectOutput
the stream to write the object to out)Implements java. The object implements the writeExternal method to save its contents by calling the methods of DataOutput for its primitive values or calling the writeObject method of ObjectOutput for objects, strings, and arrays. |
| BASE_MEMORY_USAGE | back to summary |
|---|---|
| private static final int BASE_MEMORY_USAGE | |
| pageno | back to summary |
|---|---|
| private long pageno The HeapRowLocation simply maintains a raw store record handle. | |
| recid | back to summary |
|---|---|
| private int recid | |
| RECORD_HANDLE_MEMORY_USAGE | back to summary |
|---|---|
| private static final int RECORD_HANDLE_MEMORY_USAGE | |
| rh | back to summary |
|---|---|
| private RecordHandle rh | |
| HeapRowLocation | back to summary |
|---|---|
| pack-priv HeapRowLocation(RecordHandle rh) | |
| HeapRowLocation | back to summary |
|---|---|
| public HeapRowLocation() | |
| HeapRowLocation | back to summary |
|---|---|
| private HeapRowLocation(HeapRowLocation other) | |
| cloneValue | back to summary |
|---|---|
| public DataValueDescriptor cloneValue(boolean forceMaterialization) Implements org. Doc from org. Clone this DataValueDescriptor. Results in a new object that has the same value as this but can be modified independently.
Even though the objects can be modified independently regardless of the
value of
| |
| compare | back to summary |
|---|---|
| public boolean compare(int op, DataValueDescriptor other, boolean orderedNulls, boolean unknownRV) Overrides org. Implements org. Doc from org. Compare this Orderable with a given Orderable for the purpose of qualification and sorting. The caller gets to determine how nulls should be treated - they can either be ordered values or unknown values.
| |
| compare | back to summary |
|---|---|
| public int compare(DataValueDescriptor other) Implements org. Doc from org. Compare this Orderable with a given Orderable for the purpose of index positioning. This method treats nulls as ordered values - that is, it treats SQL null as equal to null and greater than all other values.
| |
| equals | back to summary |
|---|---|
| public boolean equals(Object ref) Overrides org. Implement value equality.
| |
| estimateMemoryUsage | back to summary |
|---|---|
| public int estimateMemoryUsage() Implements org. Doc from org. Estimate the memory usage in bytes of the data value and the overhead of the class.
| |
| getLength | back to summary |
|---|---|
| public int getLength() Implements org. Doc from org. Gets the length of the data value. The meaning of this is implementation-dependent. For string types, it is the number of characters in the string. For numeric types, it is the number of bytes used to store the number. This is the actual length of this value, not the length of the type it was defined as. For example, a VARCHAR value may be shorter than the declared VARCHAR (maximum) length.
| |
| getNewNull | back to summary |
|---|---|
| public DataValueDescriptor getNewNull() Implements org. Doc from org. Get a new null value of the same type as this data value. | |
| getObject | back to summary |
|---|---|
| public Object getObject() Overrides org. Implements org. Doc from org. Gets the value in the data value descriptor as a Java Object. The type of the Object will be the Java object type corresponding to the data value's SQL type. JDBC defines a mapping between Java object types and SQL types - we will allow that to be extended through user type definitions. Throws an exception if the data value is not an object (yeah, right).
| |
| getRecordHandle | back to summary |
|---|---|
| public RecordHandle getRecordHandle(ContainerHandle ch) throws StandardException | |
| getString | back to summary |
|---|---|
| public String getString() Implements org. Doc from org. Gets the value in the data value descriptor as a String. Throws an exception if the data value is not a string.
| |
| getTypeFormatId | back to summary |
|---|---|
| public int getTypeFormatId() Implements org. Return my format identifier.
| |
| getTypeName | back to summary |
|---|---|
| public String getTypeName() Implements org. Doc from org. Get the SQL name of the datatype
| |
| hashCode | back to summary |
|---|---|
| public int hashCode() Overrides java. Return a hashcode based on value.
| |
| isNull | back to summary |
|---|---|
| public boolean isNull() Implements org. Doc from org. Return whether the value is null or not.
| |
| readExternal | back to summary |
|---|---|
| public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException Implements java. Doc from java. The object implements the readExternal method to restore its contents by calling the methods of DataInput for primitive types and readObject for objects, strings and arrays. The readExternal method must read the values in the same sequence and with the same types as were written by writeExternal.
| |
| readExternalFromArray | back to summary |
|---|---|
| public void readExternalFromArray(ArrayInputStream in) throws IOException, ClassNotFoundException Overrides org. Implements org. Doc from org. Read the DataValueDescriptor from the stream. Initialize the data value by reading it's values from the ArrayInputStream. This interface is provided as a way to achieve possible performance enhancement when reading an array can be optimized over reading from a generic stream from readExternal().
| |
| recycle | back to summary |
|---|---|
| public DataValueDescriptor recycle() Overrides org. Implements org. Recycle this HeapRowLocation object.
| |
| restoreToNull | back to summary |
|---|---|
| public void restoreToNull() Implements org. Doc from org. Restore this object to its (SQL)null value. | |
| setFrom | back to summary |
|---|---|
| pack-priv void setFrom(RecordHandle rh) | |
| setFrom | back to summary |
|---|---|
| protected void setFrom(DataValueDescriptor theValue) Overrides org. Doc from org. Set the value of this DataValueDescriptor based on the value of the specified DataValueDescriptor.
| |
| setValue | back to summary |
|---|---|
| public void setValue(RowLocation rowLocation) Implements org. Doc from org. Set the value of this RefDataValue.
| |
| setValueFromResultSet | back to summary |
|---|---|
| public void setValueFromResultSet(ResultSet resultSet, int colNumber, boolean isNullable) Implements org. Doc from org. Set the value based on the value for the specified DataValueDescriptor from the specified ResultSet.
| |
| toString | back to summary |
|---|---|
| public String toString() Overrides java. Doc from java. Returns a string representation of the object.
Satisfying this method's contract implies a non-
| |
| writeExternal | back to summary |
|---|---|
| public void writeExternal(ObjectOutput out) throws IOException Implements java. Doc from java. The object implements the writeExternal method to save its contents by calling the methods of DataOutput for its primitive values or calling the writeObject method of ObjectOutput for objects, strings, and arrays.
| |