forked from slizaa/slizaa-opencypher-xtext
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Model combined UNION queries as a sequence of SingleQuery's
This also pushes `union` and `singleQuery` properties down from the RegularQuery to the new CombinedQuery interface. This way, SingleQuery is cleaned from those unused properties. When 3 or more SingleQueries built up a union query, it used to be modeled as a tree where each union node added one more SingleQuery like ``` S1 UNION S2 UNION S3 ``` was modeled as ``` RegularQuery +-singleQuery: RegularQuery | +-singleQuery: SingleQuery S1 | +-union: | +-[list entry]: Union | +-singleQuery: SingleQuery S2 +-union: +-list entry: Union +-singleQuery: SingleQuery S3 ``` From now, the representation is as follows, where RegularQuery has 2 subclasses: - SingleQuery used for sole queries not having any UNION clauses - CombinedQuery used for queries that have at least one query combinator (UNION in current openCypher, but other set combinators like INTERSECT are about to come, see opencypher/openCypher#227) ``` CombinedQuery +-singleQuery: SingleQuery S1 +-union: +-[list entry]: Union +-singleQuery: SingleQuery S2 +-[list entry]: Union +-singleQuery: SingleQuery S3 ```
- Loading branch information
Showing
4 changed files
with
37 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters