Fennel: LcsCompareColKeyUsingOffsetIndex Class Reference (original) (raw)

This class implements the compare logic to sort the indices to the key offset vector, by comparing the data values stored at thse offsets. More...

#include <[LcsHash.h](LcsHash%5F8h-source.html)>

List of all members.

Public Member Functions
LcsCompareColKeyUsingOffsetIndex (SharedLcsClusterNodeWriter clusterBlockWriterInit, LcsHashTable *hashTableInit, TupleDescriptor const &colTupleDescInit, uint columnIdInit, UnalignedAttributeAccessor const &attrAccessorInit)
Constructor.
~LcsCompareColKeyUsingOffsetIndex ()
bool lessThan (const uint16_t colKeyOffsetIndex1, const uint16_t colKeyOffsetIndex2)
Compares the two values stored at the offsets located by the two indices.
Private Attributes
LcsHashTable * hashTable
Reference to the Hash Table where cluster column values are inserted into.
SharedLcsClusterNodeWriter clusterBlockWriter
Reference to Node Writer to access the cluster column value.
uint columnId
Column Id for this cluster column.
TupleDataWithBuffer colTuple1
Two tuple instances to store the values being compared.
TupleDataWithBuffer colTuple2
TupleDescriptor colTupleDesc
Tuple descriptor for the tuples being compared.
UnalignedAttributeAccessor attrAccessor

Detailed Description

This class implements the compare logic to sort the indices to the key offset vector, by comparing the data values stored at thse offsets.

The sorted indices can then be used to encode the offsets when preparing a compressed batch to write out.

Definition at line 322 of file LcsHash.h.


Constructor & Destructor Documentation

| LcsCompareColKeyUsingOffsetIndex::~LcsCompareColKeyUsingOffsetIndex | ( | | ) | [inline] | | -------------------------------------------------------------------- | - | | - | ---------- |


Member Function Documentation

bool LcsCompareColKeyUsingOffsetIndex::lessThan ( const uint16_t colKeyOffsetIndex1,
const uint16_t colKeyOffsetIndex2
)

Compares the two values stored at the offsets located by the two indices.

The implementation uses type information saved in colTupleDesc when performing the comparison.

Parameters:

[in] colKeyOffsetIndex1 index into the offset of the first value
[in] colKeyOffsetIndex2 index into the offset of the second value

Returns:

true if value at offset located at colKeyOffsetIndex1 is less than value at offset loocated at colKeyOffsetIndex2

Definition at line 588 of file LcsHash.cpp.

References attrAccessor, clusterBlockWriter, colTuple1, colTuple2, colTupleDesc, columnId, TupleDescriptor::compareTuples(), hashTable, UnalignedAttributeAccessor::loadValue(), TupleDataWithBuffer::resetBuffer(), LcsHashTable::valueNodes, and LcsHashValueNode::valueOffset.


Member Data Documentation


The documentation for this class was generated from the following files:


Generated on Mon Jun 22 04:00:37 2009 for Fennel by doxygen 1.5.1