Skip to content

Feature: Add API for XPath parsing and processing (TEDEFO-2401)#23

Merged
bertrand-lorentz merged 5 commits intodevelopfrom
feature/add-xpath-api
Oct 20, 2023
Merged

Feature: Add API for XPath parsing and processing (TEDEFO-2401)#23
bertrand-lorentz merged 5 commits intodevelopfrom
feature/add-xpath-api

Conversation

@bertrand-lorentz
Copy link
Copy Markdown
Contributor

This consolidates the various XPath processing capabilities from the EFX toolkit into the eForms core library. See commit messages for more details.

This just adds APIs, so existing usage is not impacted. The removal of the corresponding features from the EFX toolkit is prepared and will be in a PR there once this is OK.

I'd welcome suggestions on the names of the new classes in the added API (XPathProcessor and XPathInfo).

The ANTLR4 grammar is the same that was used in the EFX toolkit.
Java code is generated from this grammar at build time.
Using a newer version causes errors
This consolidates the XPath parsing and manipulation done in various
parts of the EFX toolkit into a single XPathProcessor class.
Most of the code is copied over from the EFX toolkit.

Unit tests are also copied from the corresponding tests in EFX tookit,
with some new ones added.
Also indicate how to generate the report in the main README.
Copy link
Copy Markdown
Contributor

@rouschr rouschr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Apart from JavaDocs and formatting, I think as there are unit tests this should be at good start.

Comment thread src/main/java/eu/europa/ted/eforms/xpath/XPathInfo.java Outdated
Comment thread src/main/java/eu/europa/ted/eforms/xpath/XPathListenerImpl.java Outdated
Comment thread src/main/java/eu/europa/ted/eforms/xpath/XPathStep.java Outdated
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants