Examples of FixedSizeBigIntegerNullSerializer


Examples of org.helidb.lang.serializer.FixedSizeBigIntegerNullSerializer

      DatabaseBackend<String, String, Long> b = new HeapBackend<String, String>(new ReadWritableFileAdapter(f), false, StringSerializer.INSTANCE, StringSerializer.INSTANCE, 0, 8192, lah);

      // Maximum pointer needed: approx 1,000,000 * node size
      // approx: 1,000,000 * 20 = 20,000,000 < 4294967296 =
      // 2 ^ (4 * 8). i.e pointer size = 4 bytes
      NodeRepository<BigInteger> nr = new FileBackedNodeRepository<BigInteger, Long>(new ReadWritableFileAdapter(treef), false, 0, new FixedSizeNodeSizeStrategy(m_bTreeNodeSize), true, new FixedSizeBigIntegerNullSerializer(STRING_HASH_SIZE + 1), LongNullSerializer.INSTANCE, 4, 8192, null, lah);
      if (m_bTreeLruNodeCacheSize > 0)
      {
        nr = new LruCacheNodeRepository<BigInteger, Long>(nr, m_bTreeLruNodeCacheSize);
      }
      BPlusTree<BigInteger, Long> btree = new BPlusTree<BigInteger, Long>(nr, lah);
View Full Code Here

Examples of org.helidb.lang.serializer.FixedSizeBigIntegerNullSerializer

      DatabaseBackend<String, String, Long> b = new HeapBackend<String, String>(new ReadWritableFileAdapter(f), false, StringSerializer.INSTANCE, StringSerializer.INSTANCE, 0, 8192, lah);

      // Maximum pointer needed: approx 1,000,000 * node size
      // approx: 1,000,000 * 20 = 20,000,000 < 4294967296 =
      // 2 ^ (4 * 8). i.e pointer size = 4 bytes
      NodeRepository<BigInteger> nr = new FileBackedNodeRepository<BigInteger, Long>(new ReadWritableFileAdapter(treef), false, 0, new FixedSizeNodeSizeStrategy(m_bTreeNodeSize), true, new FixedSizeBigIntegerNullSerializer(STRING_HASH_SIZE + 1), LongSerializer.INSTANCE, 4, 8192, null, lah);
      if (m_bTreeLruNodeCacheSize > 0)
      {
        nr = new LruCacheNodeRepository<BigInteger, Long>(nr, m_bTreeLruNodeCacheSize);
      }
      BPlusTree<BigInteger, Long> btree = new BPlusTree<BigInteger, Long>(nr, lah);
View Full Code Here

Examples of org.helidb.lang.serializer.FixedSizeBigIntegerNullSerializer

      File indf = FileSupport.createTempFile();
      ReadWritableFile indff = new ReadWritableFileAdapter(indf);
      File tmpDir = FileSupport.createTempDirectory();
      Directory tmpDirD = new FSRWFileSystemBuilder().setRoot(tmpDir).create().getRootDirectory();

      NodeRepositoryBuilder<BigInteger> nrb = new FileBackedNodeRepositoryBuilder<BigInteger, Long>().setNodeSizeStrategy(new FixedSizeNodeSizeStrategy(m_bTreeNodeSize)).setKeySerializer(new FixedSizeBigIntegerNullSerializer(STRING_HASH_SIZE + 1)).setValueSerializer(LongSerializer.INSTANCE);
      if (m_bTreeLruNodeCacheSize > 0)
      {
        nrb = new LruCacheNodeRepositoryBuilder<BigInteger, Long>().setProxiedBuilder(nrb).setMaxCacheSize(m_bTreeLruNodeCacheSize);
      }
      DatabaseBackendFactory<String, String, Long> baf = new HeapBackendFactory<String, String>(StringSerializer.INSTANCE, StringSerializer.INSTANCE, lah);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.