Package com.adobe.xfa
Class SOMParser
- java.lang.Object
-
- com.adobe.xfa.SOMParser
-
public final class SOMParser extends java.lang.ObjectSOMParser provides support for resolving a SOM (Scripting Object Model) expression into a list of nodes.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classSOMParser.SomResultInfoDescribes one returned value from the SOM parser.
-
Constructor Summary
Constructors Constructor Description SOMParser()Constructs a new SOMParser.SOMParser(DependencyTracker dependencyTracker)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanresolve(Node startNode, java.lang.String somExpression, java.lang.Object[] objectParameters, java.util.List<SOMParser.SomResultInfo> result, BooleanHolder isAssociation)booleanresolve(Node startNode, java.lang.String somExpression, java.util.List<SOMParser.SomResultInfo> result)Resolves a SOM expression to the list of Obj that the SOM expression represents.booleanresolve(Node startNode, java.lang.String somExpression, java.util.List<SOMParser.SomResultInfo> result, BooleanHolder isAssociation)Resolves a SOM expression to the list of Obj that the SOM expression represents.voidsetDependencyTracker(DependencyTracker dependencyTracker)Sets the DependencyTracker for the parservoidsetOptions(boolean bPeek, boolean bLastInstance, boolean bNoProperties)Set the options for the parser
-
-
-
Constructor Detail
-
SOMParser
public SOMParser(DependencyTracker dependencyTracker)
-
SOMParser
public SOMParser()
Constructs a new SOMParser.
-
-
Method Detail
-
resolve
public boolean resolve(Node startNode, java.lang.String somExpression, java.util.List<SOMParser.SomResultInfo> result)
Resolves a SOM expression to the list of Obj that the SOM expression represents.- Parameters:
startNode- the Node to start at (the current node)somExpression- the SOM expression to be resolved.result- a List of SomResultInfo that will be populated with the result of evaluating the SOM expression.- Returns:
trueif any nodes were added to the result.
-
resolve
public boolean resolve(Node startNode, java.lang.String somExpression, java.util.List<SOMParser.SomResultInfo> result, BooleanHolder isAssociation)
Resolves a SOM expression to the list of Obj that the SOM expression represents.- Parameters:
startNode- the Node to start at (the current node)somExpression- the SOM expression to be resolved.result- a List of SomResultInfo that will be populated with the result of evaluating the SOM expression.isAssociation- (out) will be set totrueif the nodes returned include an association- Returns:
trueif any nodes were added to the result.
-
resolve
public boolean resolve(Node startNode, java.lang.String somExpression, java.lang.Object[] objectParameters, java.util.List<SOMParser.SomResultInfo> result, BooleanHolder isAssociation)
-
setOptions
public void setOptions(boolean bPeek, boolean bLastInstance, boolean bNoProperties)Set the options for the parser- Parameters:
bPeek- - if true do not create any default children. Defaults to falsebLastInstance- - if true "*" is used return only the last instance. Defaults to falsebNoProperties- - if true no properties (such as x.name) are returned. Note that if name were a child node, it would be returned. Defaults to false
-
setDependencyTracker
public void setDependencyTracker(DependencyTracker dependencyTracker)
Sets the DependencyTracker for the parser- Parameters:
dependencyTracker- the dependency tracker for the next call to resolve
-
-