Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: textContains expr. function [DHIS2-16211] #48

Merged
merged 3 commits into from
Jan 24, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<packaging>jar</packaging>
<name>DHIS Antlr Expression Parser</name>
<groupId>org.hisp.dhis.parser</groupId>
<version>1.0.34-SNAPSHOT</version>
<version>1.0.35</version>

<description>Antlr Expression Parser</description>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,11 @@ grammar Expression;
// Parser rules
// -----------------------------------------------------------------------------

// Note: ANTLR symbols for optional or repeating:
// ? -> 0 or 1
// * -> 0 or more
// + -> 1 or more

expression // The expression must last until the end of the string
: expr EOF
;
Expand Down Expand Up @@ -59,6 +64,7 @@ expr
| it='orgUnit.program(' WS* UID WS* (',' WS* UID WS* )* ')'
| it='removeZeros(' expr ')'
| it='subExpression(' expr ')'
| it='textContains(' expr (',' expr )+ ')'

// Aggergation functions (alphabetical)

Expand Down Expand Up @@ -303,6 +309,7 @@ ORGUNIT_GROUP : 'orgUnit.group(';
ORGUNIT_PROGRAM : 'orgUnit.program(';
REMOVE_ZEROS : 'removeZeros(';
SUB_EXPRESSION : 'subExpression(';
TEXT_CONTAINS : 'textContains(';

// Aggegation functions (alphabetical)

Expand Down
Loading