|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.jclark.xsl.expr.ExprTokenizer
com.jclark.xsl.expr.ExprParser
XPAth expression parser / compiler extends the lexer ExprTokenizer
Field Summary | |
(package private) int |
currentToken
|
(package private) java.lang.String |
currentTokenValue
|
(package private) static int |
TOK_AND
|
(package private) static int |
TOK_AT
|
(package private) static int |
TOK_AXIS
|
(package private) static int |
TOK_CNAME_LPAR
|
(package private) static int |
TOK_COMMA
|
(package private) static int |
TOK_COMMENT_LPAR
|
(package private) static int |
TOK_DIV
|
(package private) static int |
TOK_DOT
|
(package private) static int |
TOK_DOT_DOT
|
(package private) static int |
TOK_EOF
|
(package private) static int |
TOK_EQUALS
|
(package private) static int |
TOK_FUNCTION_LPAR
|
(package private) static int |
TOK_GT
|
(package private) static int |
TOK_GTE
|
(package private) static int |
TOK_LITERAL
|
(package private) static int |
TOK_LPAR
|
(package private) static int |
TOK_LSQB
|
(package private) static int |
TOK_LT
|
(package private) static int |
TOK_LTE
|
(package private) static int |
TOK_MINUS
|
(package private) static int |
TOK_MOD
|
(package private) static int |
TOK_MULTIPLY
|
(package private) static int |
TOK_NAME_COLON_STAR
|
(package private) static int |
TOK_NODE_LPAR
|
(package private) static int |
TOK_NOT_EQUALS
|
(package private) static int |
TOK_NUMBER
|
(package private) static int |
TOK_OR
|
(package private) static int |
TOK_PLUS
|
(package private) static int |
TOK_PROCESSING_INSTRUCTION_LPAR
|
(package private) static int |
TOK_QNAME
|
(package private) static int |
TOK_RPAR
|
(package private) static int |
TOK_RSQB
|
(package private) static int |
TOK_SLASH
|
(package private) static int |
TOK_SLASH_SLASH
|
(package private) static int |
TOK_STAR
|
(package private) static int |
TOK_TEXT_LPAR
|
(package private) static int |
TOK_VARIABLE_REF
|
(package private) static int |
TOK_VBAR
|
Fields inherited from interface com.jclark.xsl.om.NamespaceConstants |
XFYXT_NAMESPACE, XT_NAMESPACE |
Method Summary | |
(package private) static boolean |
functionAvailable(Name name,
ExprContext context)
|
static NodeSetExpr |
getChildrenExpr()
|
(package private) ConvertibleExpr |
makeRelationalExpr(Relation rel,
ConvertibleExpr e1,
ConvertibleExpr e2)
A ConvertibleExpr allows for the casting of one type to another for the purpose of making a comparison |
(package private) void |
next()
lexes the next token, leaving the token type in currentToken , and the value (if applicable) in
tokenValue |
static BooleanExpr |
parseBooleanExpr(Node node,
java.lang.String expr,
VariableSet locals)
parse an XPath expression which is to be used in a context in which a Boolean is expected |
static NodeSetExpr |
parseNodeSetExpr(Node node,
java.lang.String expr,
VariableSet locals)
parse an XPath expression which is to be used in a context in which a NodeSet is expected i.e. |
static NumberExpr |
parseNumberExpr(Node node,
java.lang.String expr,
VariableSet locals)
parse an XPath expression which is to be used in a context in which a Number is expected |
static TopLevelPattern |
parsePattern(Node node,
java.lang.String pattern)
parse an XPath match Pattern |
static TopLevelPattern |
parsePattern(Node node,
java.lang.String pattern,
VariableSet locals)
parse an XPath match pattern (with some variables!?!?) |
static StringExpr |
parseStringExpr(Node node,
java.lang.String expr,
VariableSet locals)
parse an XPath expression which is to be used in a context in which a String is expected |
static StringExpr |
parseValueExpr(Node node,
java.lang.String value,
VariableSet locals)
parse an XSLT attribute value template (which may include XPath expression(s) enclosed in curlybraces "{" "}") |
static VariantExpr |
parseVariantExpr(Node node,
java.lang.String expr,
VariableSet locals)
parse an XPath expression which is to be used in a context in which a Variant (xsl:variable, xsl:param) is expected |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
static final int TOK_EOF
static final int TOK_QNAME
static final int TOK_STAR
static final int TOK_NAME_COLON_STAR
static final int TOK_AT
static final int TOK_DOT
static final int TOK_DOT_DOT
static final int TOK_COMMENT_LPAR
static final int TOK_PROCESSING_INSTRUCTION_LPAR
static final int TOK_TEXT_LPAR
static final int TOK_NODE_LPAR
static final int TOK_MULTIPLY
static final int TOK_LPAR
static final int TOK_RPAR
static final int TOK_LSQB
static final int TOK_RSQB
static final int TOK_LITERAL
static final int TOK_NUMBER
static final int TOK_AXIS
static final int TOK_FUNCTION_LPAR
static final int TOK_CNAME_LPAR
static final int TOK_VARIABLE_REF
static final int TOK_SLASH
static final int TOK_SLASH_SLASH
static final int TOK_VBAR
static final int TOK_COMMA
static final int TOK_PLUS
static final int TOK_MINUS
static final int TOK_EQUALS
static final int TOK_NOT_EQUALS
static final int TOK_GT
static final int TOK_LT
static final int TOK_GTE
static final int TOK_LTE
static final int TOK_AND
static final int TOK_OR
static final int TOK_MOD
static final int TOK_DIV
int currentToken
java.lang.String currentTokenValue
Method Detail |
public static StringExpr parseValueExpr(Node node, java.lang.String value, VariableSet locals) throws XSLException
XSLException
public static NodeSetExpr getChildrenExpr()
public static TopLevelPattern parsePattern(Node node, java.lang.String pattern) throws XSLException
XSLException
public static TopLevelPattern parsePattern(Node node, java.lang.String pattern, VariableSet locals) throws XSLException
node
- represents the node in the stylesheet
with the expression we're parsing. Used for
plugging the location in any Exception we might throw
xsl:number allows variables in the "count" and "from" attributes
XSLException
public static NodeSetExpr parseNodeSetExpr(Node node, java.lang.String expr, VariableSet locals) throws XSLException
XSLException
public static StringExpr parseStringExpr(Node node, java.lang.String expr, VariableSet locals) throws XSLException
XSLException
public static NumberExpr parseNumberExpr(Node node, java.lang.String expr, VariableSet locals) throws XSLException
XSLException
public static BooleanExpr parseBooleanExpr(Node node, java.lang.String expr, VariableSet locals) throws XSLException
XSLException
public static VariantExpr parseVariantExpr(Node node, java.lang.String expr, VariableSet locals) throws XSLException
XSLException
ConvertibleExpr makeRelationalExpr(Relation rel, ConvertibleExpr e1, ConvertibleExpr e2) throws ParseException
ParseException
static boolean functionAvailable(Name name, ExprContext context) throws XSLException
XSLException
void next() throws ParseException
currentToken
, and the value (if applicable) in
tokenValue
ParseException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |