Package org.neo4j.shell.tools.imp.format.graphml

Examples of org.neo4j.shell.tools.imp.format.graphml.XmlGraphMLReader$Key


    validateQuery(query);
    validateSplitSize(numSplits);

    List<Query> splits = new ArrayList<Query>(numSplits);
    List<Key> scatterKeys = getScatterKeys(numSplits, query, datastore);
    Key lastKey = null;
    for (Key nextKey : getSplitKey(scatterKeys, numSplits)) {
      splits.add(createSplit(lastKey, nextKey, query));
      lastKey = nextKey;
    }
    splits.add(createSplit(lastKey, null, query));
View Full Code Here


    private GraphDatabaseService gdb;

    @Before
    public void setUp() throws Exception {
        gdb = new TestGraphDatabaseFactory().newImpermanentDatabase();
        graphMLReader = new XmlGraphMLReader(gdb).storeNodeIds();
    }
View Full Code Here

                .setConfig(GraphDatabaseSettings.strings_mapped_memory_size,String.valueOf(100*MEGABYTE))
                .setConfig(GraphDatabaseSettings.keep_logical_logs, "false")
                .newGraphDatabase();

        reader = new CountingReader(graphMlFile);
        graphMlReader = new XmlGraphMLReader(db).reporter(new ProgressReporter(reader,new SystemOutput()));
    }
View Full Code Here

    private long execute(CountingReader reader, int batchSize, String relType, boolean diskSpillCache, boolean readLabels, Output out) throws XMLStreamException, IOException {
        try {
            GraphDatabaseAPI db = getServer().getDb();
            ProgressReporter reporter = new ProgressReporter(reader, out);
            XmlGraphMLReader graphMLReader = new XmlGraphMLReader(db)
                    .batchSize(batchSize).relType(relType)
                    .nodeLabels(readLabels)
                    .reporter(reporter);
            NodeCache cache = diskSpillCache ? MapNodeCache.usingMapDb() : MapNodeCache.usingHashMap();
            return graphMLReader.parseXML(reader, cache);
        } finally {
            reader.close();
        }
    }
View Full Code Here

TOP

Related Classes of org.neo4j.shell.tools.imp.format.graphml.XmlGraphMLReader$Key

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.