Skip to content

Commit

Permalink
Prepare relase.
Browse files Browse the repository at this point in the history
  • Loading branch information
michael-simons committed Jul 8, 2021
1 parent b006d66 commit c840b8f
Show file tree
Hide file tree
Showing 4 changed files with 43 additions and 2 deletions.
2 changes: 1 addition & 1 deletion README.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
:groupId: org.neo4j
:artifactId: neo4j-cypher-dsl

:neo4j-cypher-dsl-version: 2021.2.4-SNAPSHOT
:neo4j-cypher-dsl-version: 2021.3.0

// end::properties[]

Expand Down
38 changes: 38 additions & 0 deletions docs/appendix/2021.3.adoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
== 2021.3

=== 2021.3.0

==== 🚀 New module: The Cypher-DSL-Parser

2021.3 builds straight upon <<2021.2.3>>, with few additions to the existing API, that didn't quite fit with a patch release,
but belong conceptually into this release, which brings a completely new module: The `neo4j-cypher-dsl-parser`.

What's behind that name? A Cypher-Parser build on the official Neo4j 4.3 parser frontend and creating a Cypher-DSL-AST or
single expressions usable in the context of the Cypher-DSL.

The module lives under the following coordinates `org.neo4j:neo4j-cypher-dsl-parser` and requires JDK 11+ (the same version like Neo4j does).
We created a couple of <<cypher-parser-examples,examples>>, but we are sure you will have tons of more ideas and therefore
a looking for your feedback.

Here's a sneak preview. It shows you can add a user supplied Cypher fragment to something you are building using the DSL.

[source,java]
----
var userProvidedCypher
= "MATCH (this)-[:LINK]-(o:Other) RETURN o as result";
var userStatement = CypherParser.parse(userProvidedCypher);
var node = Cypher.node("Node").named("node");
var result = Cypher.name("result");
var cypher = Cypher
.match(node)
.call(
userStatement,
node.as("this")
)
.returning(result.project("foo", "bar"))
.build()
.getCypher();
----

For this release a big thank you goes out to the Cypher-operations team at Neo4j, listening to our requests and ideas!
2 changes: 2 additions & 0 deletions docs/appendix/changes.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

:leveloffset: +1

include::2021.3.adoc[]

include::2021.2.adoc[]

include::2021.1.adoc[]
Expand Down
3 changes: 2 additions & 1 deletion docs/cypher-parser/cypher-parser.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ It provides a list of static methods:
|`parseStatement`
|Parses a whole statement. The result can be rendered or used in a union or subquery call.

|`parses`
|`parse`
|An alias for `parseStatement`.

|===
Expand All @@ -96,6 +96,7 @@ allowing to interact with the parser. Please have a look at the JavaAPI for info
The following examples show some ways of using it.
Most of the configurable options represent ways to provide filters for labels or types or are callbacks when certain expressions are created.

[[cypher-parser-examples]]
== Examples

=== Parsing user input and call in a subquery
Expand Down

0 comments on commit c840b8f

Please sign in to comment.