Skip to content

Commit

Permalink
add Neo4J usage example to README
Browse files Browse the repository at this point in the history
  • Loading branch information
danthe1st committed Aug 4, 2024
1 parent 28ecb85 commit 9522025
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,4 +36,13 @@ In order to use that algorithm on custom graph implementation/graph databases, o

### arebac-neo4j

The `arebac-neo4j` module contains an implementation of `AttributedGraph` that uses an embedded Neo4J database that can be used to evaluate graph patterns against a Neo4J database with the GP-Eval algorithm.
The `arebac-neo4j` module contains an implementation of `AttributedGraph` that uses an embedded Neo4J database that can be used to evaluate graph patterns against a Neo4J database with the GP-Eval algorithm.

```java
GraphDatabaseService database = getDatabase();
GraphPattern pattern = createGraphPattern();
try(Transaction tx = database.beginTx()){
Set<List<Neo4jNode>> results = GPEval.evaluate(dbAsGraph, pattern);
System.out.println(results);
}
```

0 comments on commit 9522025

Please sign in to comment.