Examples of Neo4jGraph


Examples of com.tinkerpop.blueprints.pgm.impls.neo4j.Neo4jGraph

public class DBpediaLoader
{
    public static void main( String[] args )
      throws SailException, RDFParseException, RDFHandlerException, FileNotFoundException, IOException
    {
      Neo4jGraph neo = new Neo4jGraph("dbpedia4neo");
      Sail sail = new GraphSail(neo);
      CommitManager manager = TransactionalGraphHelper.createCommitManager(neo, 10000);

      for (String file: args) {
        System.out.println("Loading " + file + ": ");
View Full Code Here

Examples of com.tinkerpop.blueprints.pgm.impls.neo4j.Neo4jGraph

public class Main {
  public static void main(String[] args) throws Exception {

    final Server server = new Server(8081);
    final Neo4jGraph neo  = new Neo4jGraph("dbpedia4neo");
    final GraphSail gsail = new GraphSail(neo);
    final SailGraph sail  = new SailGraph(gsail);
   
        ServletContextHandler context = new ServletContextHandler(ServletContextHandler.SESSIONS);
        context.setContextPath("/");
View Full Code Here

Examples of com.tinkerpop.blueprints.pgm.impls.neo4j.Neo4jGraph

        }
    }

    private Bindings createBindings(Map<String, Object> params) {
        final Bindings bindings = new SimpleBindings();
        bindings.put(g, new Neo4jGraph(graphDatabaseService));
        if (params==null) return bindings;
        for (Map.Entry<String, Object> entry : params.entrySet()) {
            bindings.put(entry.getKey(),entry.getValue());
        }
        return bindings;
View Full Code Here

Examples of com.tinkerpop.blueprints.pgm.impls.neo4j.Neo4jGraph

        GraphDatabaseService dbInstance = DatabaseLocator.getGraphDatabase();
        System.out.println("GremlinFactory: " + dbInstance);
        TransactionalGraph graph;
        try
        {
            graph = new Neo4jGraph( dbInstance,
                    DatabaseLocator.getIndexService() );

        }
        catch ( UnsupportedOperationException e )
        {
            // Tempary until indexing is implemented in webadmin for remote
            // databases
            graph = new Neo4jGraph( dbInstance, new MockIndexService() );
        }

        return graph;
    }
View Full Code Here

Examples of com.tinkerpop.gremlin.neo4j.structure.Neo4jGraph

        this(traversal, query, new HashMap<>());
    }

    public Neo4jCypherStep(final Traversal traversal, final String query, final Map<String, Object> parameters) {
        super(traversal);
        final Neo4jGraph graph = (Neo4jGraph) traversal.sideEffects().getGraph();
        final ExecutionEngine cypher = Neo4jHelper.getCypher(graph);
        this.setFunction(traverser -> {
            final S s = traverser.get();
            parameters.put(START, s);
            final ExecutionResult result = cypher.execute(query, parameters);
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.