Package krati.core.segment

Examples of krati.core.segment.ChannelSegmentFactory


       * Configure NetworkTypeahead
       */
      NetworkTypeaheadConfig<TypeaheadElement> config =
        TypeaheadConfigFactory.createNetworkTypeaheadConfig(properties);
      config.setElementStoreCached(false); // disable cache to bypass serialization
      config.setElementStoreSegmentFactory(new ChannelSegmentFactory());
      config.setConnectionsStoreSegmentFactory(new WriteBufferSegmentFactory(config.getConnectionsStoreSegmentMB()));
     
      WeightedNetworkTypeaheadInitializer<TypeaheadElement> initializer =
        new WeightedNetworkTypeaheadInitializer<TypeaheadElement>(config);
      WeightedNetworkTypeahead<TypeaheadElement> typeahead =
View Full Code Here


    /**
     * Configure NetworkTypeahead
     */
    config = TypeaheadConfigFactory.createNetworkTypeaheadConfig(properties);
    config.setElementStoreCached(false); // disable cache to bypass serialization
    config.setElementStoreSegmentFactory(new ChannelSegmentFactory());
    config.setConnectionsStoreSegmentFactory(new ChannelSegmentFactory());
    initializer = new WeightedNetworkTypeaheadInitializer<TypeaheadElement>(config);
   
    WeightedNetworkTypeahead<TypeaheadElement> typeahead =
      (WeightedNetworkTypeahead<TypeaheadElement>) initializer.getTypeahead();
   
View Full Code Here

*
*/
public class TestStaticDataSetChannel extends TestStaticDataSet {
    @Override
    protected SegmentFactory getSegmentFactory() {
        return new ChannelSegmentFactory();
    }
View Full Code Here

    protected Random _rand = new Random();
   
    protected DynamicDataStore create(int initialCapacity) throws Exception {
        File storeDir = DirUtils.getTestDir(getClass());
        StoreConfig config = new StoreConfig(storeDir, initialCapacity);
        config.setSegmentFactory(new ChannelSegmentFactory());
        config.setSegmentFileSizeMB(16);
        return new DynamicDataStore(config);
    }
View Full Code Here

    protected Random _rand = new Random();
   
    protected DynamicDataSet create(int initialCapacity) throws Exception {
        File storeDir = DirUtils.getTestDir(getClass());
        StoreConfig config = new StoreConfig(storeDir, initialCapacity);
        config.setSegmentFactory(new ChannelSegmentFactory());
        config.setSegmentFileSizeMB(16);
        return new DynamicDataSet(config);
    }
View Full Code Here

*
*/
public class TestDynamicDataSetChannel extends TestDynamicDataSet {
    @Override
    protected SegmentFactory getSegmentFactory() {
        return new ChannelSegmentFactory();
    }
View Full Code Here

TOP

Related Classes of krati.core.segment.ChannelSegmentFactory

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.