Examples of IdGeneratorFactory


Examples of org.neo4j.kernel.IdGeneratorFactory

     * @throws IOException
     *             If unable to create stores or name null
     */
    public static void createStore( String fileName, Map<?,?> config )
    {
        IdGeneratorFactory idGeneratorFactory = (IdGeneratorFactory) config.get(
                IdGeneratorFactory.class );
        StoreId storeId = (StoreId) config.get( StoreId.class );
        if ( storeId == null ) storeId = new StoreId();

        createEmptyStore( fileName, VERSION, idGeneratorFactory );
View Full Code Here

Examples of org.neo4j.kernel.IdGeneratorFactory

     * @throws IOException
     *             If unable to create store or name null
     */
    public static void createStore( String fileName, Map<?, ?> config )
    {
        IdGeneratorFactory idGeneratorFactory = (IdGeneratorFactory) config.get(
                IdGeneratorFactory.class );
        createEmptyStore( fileName, VERSION, idGeneratorFactory );
        DynamicStringStore.createStore( fileName + ".names",
            TYPE_STORE_BLOCK_SIZE, idGeneratorFactory, IdType.RELATIONSHIP_TYPE_BLOCK );
        RelationshipTypeStore store = new RelationshipTypeStore(
View Full Code Here

Examples of org.neo4j.kernel.IdGeneratorFactory

     * @throws IOException
     *             If unable to create property store or name null
     */
    public static void createStore( String fileName, Map<?,?> config )
    {
        IdGeneratorFactory idGeneratorFactory = (IdGeneratorFactory) config.get(
                IdGeneratorFactory.class );
               
        createEmptyStore( fileName, VERSION, idGeneratorFactory );
        int stringStoreBlockSize = DEFAULT_DATA_BLOCK_SIZE;
        int arrayStoreBlockSize = DEFAULT_DATA_BLOCK_SIZE;
View Full Code Here

Examples of org.neo4j.kernel.IdGeneratorFactory

     * @throws IOException
     *             If unable to create node store or name null
     */
    public static void createStore( String fileName, Map<?, ?> config )
    {
        IdGeneratorFactory idGeneratorFactory = (IdGeneratorFactory) config.get(
                IdGeneratorFactory.class );
        createEmptyStore( fileName, VERSION, idGeneratorFactory );
        NodeStore store = new NodeStore( fileName, config );
        NodeRecord nodeRecord = new NodeRecord( store.nextId() );
        nodeRecord.setInUse( true );
View Full Code Here

Examples of org.neo4j.kernel.IdGeneratorFactory

{
    @Test
    public void testIt() throws Exception
    {
        int sizePerJump = 1000;
        IdGeneratorFactory factory = new JumpingIdGeneratorFactory( sizePerJump );
        IdGenerator generator = factory.get( IdType.NODE );
        for ( int i = 0; i < sizePerJump/2; i++ )
        {
            assertEquals( (long)i, generator.nextId() );
        }
       
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.