Package jdbm.helper

Examples of jdbm.helper.StringComparator


            tmpDir = new File( System.getProperty( TEST_OUTPUT_PATH ) );
        }

        dbFile = File.createTempFile( KeyBTreeCursorTest.class.getName(), "db", tmpDir );
        recman = new BaseRecordManager( dbFile.getAbsolutePath() );
        comparator = new StringComparator();
        bt = new BTree<String, byte[]>( recman, comparator );

        // add some data to it
        bt.insert( "0", EMPTY_BYTES, true );
        bt.insert( "1", EMPTY_BYTES, true );
View Full Code Here


            tmpDir = new File( System.getProperty( TEST_OUTPUT_PATH ) );
        }

        dbFile = File.createTempFile( KeyCursorTest.class.getName(), "db", tmpDir );
        recman = new BaseRecordManager( dbFile.getAbsolutePath() );
        comparator = new StringComparator();
        bt = new BTree<String, byte[]>( recman, comparator );

        // add some data to it
        bt.insert( "0", EMPTY_BYTES, true );
        bt.insert( "1", EMPTY_BYTES, true );
View Full Code Here

      java.util.Properties props = new java.util.Properties();
      props.put( RecordManagerOptions.CACHE_SIZE, "500" );
      props.put( RecordManagerOptions.DISABLE_TRANSACTIONS, "true" );
      recman = RecordManagerFactory.createRecordManager(results_file_name,props);
      results_file.delete();
      result_set = BTree.createInstance(recman,new StringComparator());
    }
    catch ( Exception e )
    {
      log.warn("Problem creating results file name",e);
    }
View Full Code Here

            tmpDir = new File( System.getProperty( TEST_OUTPUT_PATH ) );
        }

        dbFile = File.createTempFile( KeyBTreeCursorTest.class.getName(), "db", tmpDir );
        recman = new BaseRecordManager( dbFile.getAbsolutePath() );
        comparator = new StringComparator();
        bt = new BTree<String, byte[]>( recman, comparator );

        // add some data to it
        bt.insert( "0", Strings.EMPTY_BYTES, true );
        bt.insert( "1", Strings.EMPTY_BYTES, true );
View Full Code Here

            tmpDir = new File( System.getProperty( TEST_OUTPUT_PATH ) );
        }

        dbFile = File.createTempFile( KeyCursorTest.class.getName(), "db", tmpDir );
        recman = new BaseRecordManager( dbFile.getAbsolutePath() );
        comparator = new StringComparator();
        bt = new BTree<String, byte[]>( recman, comparator );

        // add some data to it
        bt.insert( "0", Strings.EMPTY_BYTES, true );
        bt.insert( "1", Strings.EMPTY_BYTES, true );
View Full Code Here

        // For bigIntegerMatch -> 1.2.6.1.4.1.18060.1.1.1.2.2
        comparator = new BigIntegerComparator();
        cb.schemaObjectProduced( this, "1.2.6.1.4.1.18060.1.1.1.2.2", comparator );

        // For jdbmStringMatch -> 1.2.6.1.4.1.18060.1.1.1.2.3
        comparator = new StringComparator();
        cb.schemaObjectProduced( this, "1.2.6.1.4.1.18060.1.1.1.2.3", comparator );

    }
View Full Code Here

        String dbname = new File(System.getProperty("java.io.tmpdir"), "lastlogindb").getCanonicalPath();
        if (VERBOSE)
            System.out.println("dbname:  " + dbname);
        RecordManager stamps = RecordManagerFactory.createRecordManager(dbname, rmProps);
        BTree stampDb = BTree.createInstance(stamps, new StringComparator());

        // Scan log files looking for login records
        final Pattern loginCracker = Pattern.compile(loginRE);
        final SimpleDateFormat dateEncoder = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
View Full Code Here

TOP

Related Classes of jdbm.helper.StringComparator

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.