Package org.chaidb.db.index

Examples of org.chaidb.db.index.IDBIndex.open()


        if (openedBTree.containsKey(filename)) {
            return (BTree)openedBTree.get(filename);
        }
        String path = DbEnvironment.getDataHome().concat(filename);
        IDBIndex index = BTreeFactory.createBTree(btreeType.typeId);
        index.open(path, kc);
        BTree bTree = new BTree(this, index, btreeType, kc);
        openedBTree.put(filename, bTree);
        btree2Path.put(bTree, filename);
        return bTree;
    }
View Full Code Here


            BTreeSpec treeSpec = null;

            if ((tID = btreeName2Id.getBTreeId(btreeFileName)) == null) {
                //                tree = new BTree();
                tree = BTreeFactory.createBTree(btreeType);
                tree.open(btreeFileName, kc);

                if (tree instanceof IBTree) {
                    IBTree tmpTree = (IBTree) tree;
                    tid = tmpTree.getBtreeId();
                    treeSpec = tmpTree.getBTreeSpec();
View Full Code Here

            throw new ChaiDBException(ErrorCode.RUNTIME_ERROR_BASE, "oldBTreeFileName is null");
        }
        short btreeType = getBTreeTypeFromBTreeName(oldBTreeFileName);

        IDBIndex oldBTree = BTreeFactory.createBTree(btreeType);
        oldBTree.open(oldBTreeFileName, kContext);
        IDBIndex clonedBTree = oldBTree.clone(dir, kContext);
        oldBTree.close();
        clonedBTree.close();
    }
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.