|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.yawlfoundation.yawl.util.YPredicateParser
public class YPredicateParser
Parses strings, replacing substrings within of the form ${expression} with the result of the expression evaluation Author: Michael Adams Date: 02/04/2010 Known subclasses: logging.YLogPredicateDecompositionParser, logging.YLogPredicateParameterParser, logging.YLogPredicateWorkItemParser, resourcing.util.LogPredicateParser, resourcing.jsf.dynform.DynTextParser Subclasses should override the 'valueOf' method to handle their own pre-parsing.
| Constructor Summary | |
|---|---|
YPredicateParser()
|
|
| Method Summary | |
|---|---|
protected String |
dateTimeString(long time)
Converts a time value to a full date & time string |
protected String |
evaluateQuery(String s,
org.jdom.Element data)
Evaluates an XQuery embedded within a delimited expression |
protected String |
evaluateXQuery(String s,
org.jdom.Document dataDoc)
|
protected String |
evaluateXQuery(String s,
org.jdom.Element data)
Evaluates an XQuery |
protected String |
getAttributeValue(Map<String,String> map,
String s)
Extracts a key from the delimited expression passed, then seeks the value corresponding to that key from the map passed |
protected String |
namesToCSV(Set<String> names)
Transforms a Set of Strings into a string of comma separated values |
String |
parse(String s)
Parses a string, replacing substrings within of the form ${expression} with the result of the expression evaluation |
protected String |
stripDelimiters(String s)
removes the surrounding ${...} from a String |
protected String |
valueOf(String s)
Evaluates an expression and returns the result. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public YPredicateParser()
| Method Detail |
|---|
public String parse(String s)
s - the string to parse
protected String valueOf(String s)
s - the string representing the expression, of the form ${expression}
protected String dateTimeString(long time)
time - the time value
protected String getAttributeValue(Map<String,String> map,
String s)
map - a map of String pairss - a string representing an expression, of the form ${expression:key},
containing the key
protected String namesToCSV(Set<String> names)
names - the Set of Strings to transform
protected String evaluateQuery(String s,
org.jdom.Element data)
s - the delimited expression, either of the form ${query} or ${expression:query}data - XML'd data that may be referenced by the expression. May be null if
the expression doesn't reference any data
protected String evaluateXQuery(String s,
org.jdom.Element data)
s - the query expressiondata - XML'd data that may be referenced by the expression. May be null if
the expression doesn't reference any data
protected String evaluateXQuery(String s,
org.jdom.Document dataDoc)
protected String stripDelimiters(String s)
s - the delimited String
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||