Search in sources :

Example 1 with BlockletBTreeBuilder

use of org.apache.carbondata.core.datastore.impl.btree.BlockletBTreeBuilder in project carbondata by apache.

the class BlockIndex method buildIndex.

/**
   * Below method will be used to load the data block
   *
   */
public void buildIndex(List<DataFileFooter> footerList) {
    // create a metadata details
    // this will be useful in query handling
    segmentProperties = new SegmentProperties(footerList.get(0).getColumnInTable(), footerList.get(0).getSegmentInfo().getColumnCardinality());
    // create a segment builder info
    BTreeBuilderInfo indexBuilderInfo = new BTreeBuilderInfo(footerList, segmentProperties.getDimensionColumnsValueSize());
    BtreeBuilder blocksBuilder = new BlockletBTreeBuilder();
    // load the metadata
    blocksBuilder.build(indexBuilderInfo);
    dataRefNode = blocksBuilder.get();
    totalNumberOfRows = footerList.get(0).getNumberOfRows();
}
Also used : BTreeBuilderInfo(org.apache.carbondata.core.datastore.BTreeBuilderInfo) BlockletBTreeBuilder(org.apache.carbondata.core.datastore.impl.btree.BlockletBTreeBuilder) BtreeBuilder(org.apache.carbondata.core.datastore.BtreeBuilder)

Aggregations

BTreeBuilderInfo (org.apache.carbondata.core.datastore.BTreeBuilderInfo)1 BtreeBuilder (org.apache.carbondata.core.datastore.BtreeBuilder)1 BlockletBTreeBuilder (org.apache.carbondata.core.datastore.impl.btree.BlockletBTreeBuilder)1