Package org.geotools.data.shapefile.index.quadtree.fs

Examples of org.geotools.data.shapefile.index.quadtree.fs.FileSystemIndexStore


                if (cnt % 100000 == 0)
                    System.out.print('\n');
            }
            if (verbose)
                System.out.println("done");
            FileSystemIndexStore store = new FileSystemIndexStore(file, order);
           
            if(leafSize > 0) {
                if (LOGGER.isLoggable(Level.FINE)) {
                    LOGGER.fine("Optimizing the tree (this might take some time)");
                }
                optimizeTree(tree, tree.getRoot(), 0, reader, shpIndex);
                if (LOGGER.isLoggable(Level.FINE)) {
                    LOGGER.fine("Tree optimized");
                }
            }
           
            if(LOGGER.isLoggable(Level.FINE)) {
                printStats(tree);
            }
            store.store(tree);
        } finally {
            tree.close();
        }
        return cnt;
    }
View Full Code Here


            if (!treeFile.exists() || (treeFile.length() == 0)) {
                return null;
            }

            try {
                FileSystemIndexStore idxStore = new FileSystemIndexStore(treeFile);
                return idxStore.load(store.shpManager.openIndexFile(), store.isMemoryMapped());
            } catch (IOException e) {
                throw new StoreException(e);
            }
        } finally {
            shpFiles.unlockRead(treeURL, writer);
View Full Code Here

TOP

Related Classes of org.geotools.data.shapefile.index.quadtree.fs.FileSystemIndexStore

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.