public class ExecutionEngine extends Object
Constructor and Description |
---|
ExecutionEngine(GraphDatabaseService database)
Creates an execution engine around the give graph database
|
ExecutionEngine(GraphDatabaseService database,
org.neo4j.kernel.impl.util.StringLogger logger)
Creates an execution engine around the give graph database
|
Modifier and Type | Method and Description |
---|---|
ExecutionResult |
execute(String query)
Executes a query and returns an iterable that contains the result set
|
ExecutionResult |
execute(String query,
Map<String,Object> params)
Executes a query and returns an iterable that contains the result set
|
String |
prettify(String query)
Turns a valid Cypher query and returns it with keywords in uppercase,
and new-lines in the appropriate places.
|
ExecutionResult |
profile(String query)
Profiles a query and returns an iterable that contains the result set.
|
ExecutionResult |
profile(String query,
Map<String,Object> params)
Profiles a query and returns an iterable that contains the result set.
|
public ExecutionEngine(GraphDatabaseService database)
database
- The database to wrappublic ExecutionEngine(GraphDatabaseService database, org.neo4j.kernel.impl.util.StringLogger logger)
database
- The database to wraplogger
- A logger for cypher-statementspublic ExecutionResult execute(String query) throws org.neo4j.cypher.CypherException
query
- The query to executeorg.neo4j.cypher.SyntaxException
- If the Query contains errors,
a SyntaxException exception might be thrownorg.neo4j.cypher.CypherException
public ExecutionResult execute(String query, Map<String,Object> params) throws org.neo4j.cypher.CypherException
query
- The query to executeparams
- Parameters for the queryorg.neo4j.cypher.SyntaxException
- If the Query contains errors,
a SyntaxException exception might be thrownorg.neo4j.cypher.CypherException
public ExecutionResult profile(String query) throws org.neo4j.cypher.CypherException
query
- The query to profileorg.neo4j.cypher.SyntaxException
- If the Query contains errors,
a SyntaxException exception might be thrownorg.neo4j.cypher.CypherException
public ExecutionResult profile(String query, Map<String,Object> params) throws org.neo4j.cypher.CypherException
query
- The query to profileparams
- Parameters for the queryorg.neo4j.cypher.SyntaxException
- If the Query contains errors,
a SyntaxException exception might be thrownorg.neo4j.cypher.CypherException
Copyright © 2002–2014 The Neo4j Graph Database Project. All rights reserved.