File tree Expand file tree Collapse file tree 1 file changed +15
-0
lines changed
src/main/java/eu/europa/ted/eforms/sdk/entity Expand file tree Collapse file tree 1 file changed +15
-0
lines changed Original file line number Diff line number Diff line change 22
33import java .util .Objects ;
44import com .fasterxml .jackson .databind .JsonNode ;
5+ import eu .europa .ted .eforms .xpath .XPathInfo ;
6+ import eu .europa .ted .eforms .xpath .XPathProcessor ;
57
68public abstract class SdkField implements Comparable <SdkField > {
79 private final String id ;
@@ -12,6 +14,7 @@ public abstract class SdkField implements Comparable<SdkField> {
1214 private final String codelistId ;
1315 private final boolean repeatable ;
1416 private SdkNode parentNode ;
17+ private XPathInfo xpathInfo ;
1518
1619 @ SuppressWarnings ("unused" )
1720 private SdkField () {
@@ -109,6 +112,18 @@ public void setParentNode(SdkNode parentNode) {
109112 this .parentNode = parentNode ;
110113 }
111114
115+ /**
116+ * Returns parsed XPath information for this field.
117+ * Provides access to attribute info, path decomposition, and predicate checks.
118+ * Lazily initialized on first access.
119+ */
120+ public XPathInfo getXpathInfo () {
121+ if (this .xpathInfo == null ) {
122+ this .xpathInfo = XPathProcessor .parse (this .xpathAbsolute );
123+ }
124+ return this .xpathInfo ;
125+ }
126+
112127 /**
113128 * Helps with hash maps collisions. Should be consistent with equals.
114129 */
You can’t perform that action at this time.
0 commit comments