/*
* reserved comment block
* DO NOT REMOVE OR ALTER!
*/
/*
* Copyright 1999-2004 The Apache Software Foundation.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/*
* $Id: OpCodes.java,v 1.1.2.1 2005/08/01 01:30:33 jeffsuttor Exp $
*/
/**
* Operations codes for XPath.
*
* Code for the descriptions of the operations codes:
* [UPPER CASE] indicates a literal value,
* [lower case] is a description of a value,
* ([length] always indicates the length of the operation,
* including the operations code and the length integer.)
* {UPPER CASE} indicates the given production,
* {description} is the description of a new production,
* (For instance, {boolean expression} means some expression
* that should be resolved to a boolean.)
* * means that it occurs zero or more times,
* + means that it occurs one or more times,
* ? means that it is optional.
*
* returns: indicates what the production should return.
*/
public class OpCodes
{
/**
* [ENDOP]
* Some operators may like to have a terminator.
* @xsl.usage advanced
*/
/**
* [EMPTY]
* Empty slot to indicate NULL.
*/
/**
* [ELEMWILDCARD]
* Means ELEMWILDCARD ("*"), used instead
* of string index in some places.
* @xsl.usage advanced
*/
/**
* [OP_XPATH]
* [length]
* {expression}
*
* returns:
* XNodeSet
* XNumber
* XString
* XBoolean
* XRTree
* XObject
* @xsl.usage advanced
*/
/**
* [OP_OR]
* [length]
* {boolean expression}
* {boolean expression}
*
* returns:
* XBoolean
* @xsl.usage advanced
*/
/**
* [OP_AND]
* [length]
* {boolean expression}
* {boolean expression}
*
* returns:
* XBoolean
* @xsl.usage advanced
*/
/**
* [OP_NOTEQUALS]
* [length]
* {expression}
* {expression}
*
* returns:
* XBoolean
* @xsl.usage advanced
*/
/**
* [OP_EQUALS]
* [length]
* {expression}
* {expression}
*
* returns:
* XBoolean
* @xsl.usage advanced
*/
/**
* [OP_LTE] (less-than-or-equals)
* [length]
* {number expression}
* {number expression}
*
* returns:
* XBoolean
* @xsl.usage advanced
*/
/**
* [OP_LT] (less-than)
* [length]
* {number expression}
* {number expression}
*
* returns:
* XBoolean
* @xsl.usage advanced
*/
/**
* [OP_GTE] (greater-than-or-equals)
* [length]
* {number expression}
* {number expression}
*
* returns:
* XBoolean
* @xsl.usage advanced
*/
/**
* [OP_GT] (greater-than)
* [length]
* {number expression}
* {number expression}
*
* returns:
* XBoolean
* @xsl.usage advanced
*/
/**
* [OP_PLUS]
* [length]
* {number expression}
* {number expression}
*
* returns:
* XNumber
* @xsl.usage advanced
*/
/**
* [OP_MINUS]
* [length]
* {number expression}
* {number expression}
*
* returns:
* XNumber
* @xsl.usage advanced
*/
/**
* [OP_MULT]
* [length]
* {number expression}
* {number expression}
*
* returns:
* XNumber
* @xsl.usage advanced
*/
/**
* [OP_DIV]
* [length]
* {number expression}
* {number expression}
*
* returns:
* XNumber
* @xsl.usage advanced
*/
/**
* [OP_MOD]
* [length]
* {number expression}
* {number expression}
*
* returns:
* XNumber
* @xsl.usage advanced
*/
/**
* [OP_QUO]
* [length]
* {number expression}
* {number expression}
*
* returns:
* XNumber
* @xsl.usage advanced
*/
/**
* [OP_NEG]
* [length]
* {number expression}
*
* returns:
* XNumber
* @xsl.usage advanced
*/
/**
* [OP_STRING] (cast operation)
* [length]
* {expression}
*
* returns:
* XString
* @xsl.usage advanced
*/
/**
* [OP_BOOL] (cast operation)
* [length]
* {expression}
*
* returns:
* XBoolean
* @xsl.usage advanced
*/
/**
* [OP_NUMBER] (cast operation)
* [length]
* {expression}
*
* returns:
* XBoolean
* @xsl.usage advanced
*/
/**
* [OP_UNION]
* [length]
* {PathExpr}+
*
* returns:
* XNodeSet
* @xsl.usage advanced
*/
/**
* [OP_LITERAL]
* [3]
* [index to token]
*
* returns:
* XString
* @xsl.usage advanced
*/
/** The low opcode for nodesets, needed by getFirstPredicateOpPos and
* getNextStepPos. */
/**
* [OP_VARIABLE]
* [4]
* [index to namespace token, or EMPTY]
* [index to function name token]
*
* returns:
* XString
* @xsl.usage advanced
*/
/**
* [OP_GROUP]
* [length]
* {expression}
*
* returns:
* XNodeSet
* XNumber
* XString
* XBoolean
* XRTree
* XObject
* @xsl.usage advanced
*/
/**
* [OP_EXTFUNCTION] (Extension function.)
* [length]
* [index to namespace token]
* [index to function name token]
* {OP_ARGUMENT}
*
* returns:
* XNodeSet
* XNumber
* XString
* XBoolean
* XRTree
* XObject
* @xsl.usage advanced
*/
/**
* [OP_FUNCTION]
* [length]
* [FUNC_name]
* {OP_ARGUMENT}
* [ENDOP]
*
* returns:
* XNodeSet
* XNumber
* XString
* XBoolean
* XRTree
* XObject
* @xsl.usage advanced
*/
/** The last opcode for stuff that can be a nodeset. */
/**
* [OP_ARGUMENT] (Function argument.)
* [length]
* {expression}
*
* returns:
* XNodeSet
* XNumber
* XString
* XBoolean
* XRTree
* XObject
* @xsl.usage advanced
*/
/**
* [OP_NUMBERLIT] (Number literal.)
* [3]
* [index to token]
*
* returns:
* XString
* @xsl.usage advanced
*/
/**
* [OP_LOCATIONPATH]
* [length]
* {FROM_stepType}
* | {function}
* {predicate}
* [ENDOP]
*
* (Note that element and attribute namespaces and
* names can be wildcarded '*'.)
*
* returns:
* XNodeSet
* @xsl.usage advanced
*/
// public static final int LOCATIONPATHEX_MASK = 0x0000FFFF;
// public static final int LOCATIONPATHEX_ISSIMPLE = 0x00010000;
// public static final int OP_LOCATIONPATH_EX = (28 | 0x00010000);
/**
* [OP_PREDICATE]
* [length]
* {expression}
* [ENDOP] (For safety)
*
* returns:
* XBoolean or XNumber
* @xsl.usage advanced
*/
/**
* [OP_MATCHPATTERN]
* [length]
* {PathExpr}+
*
* returns:
* XNodeSet
* @xsl.usage advanced
*/
/**
* [OP_LOCATIONPATHPATTERN]
* [length]
* {FROM_stepType}
* | {function}{predicate}
* [ENDOP]
* returns:
* XNodeSet
* @xsl.usage advanced
*/
/**
* [NODETYPE_COMMENT]
* No size or arguments.
* Note: must not overlap function OP number!
*
* returns:
* XBoolean
* @xsl.usage advanced
*/
/**
* [NODETYPE_TEXT]
* No size or arguments.
* Note: must not overlap function OP number!
*
* returns:
* XBoolean
* @xsl.usage advanced
*/
/**
* [NODETYPE_PI]
* [index to token]
* Note: must not overlap function OP number!
*
* returns:
* XBoolean
* @xsl.usage advanced
*/
/**
* [NODETYPE_NODE]
* No size or arguments.
* Note: must not overlap function OP number!
*
* returns:
* XBoolean
* @xsl.usage advanced
*/
/**
* [NODENAME]
* [index to ns token or EMPTY]
* [index to name token]
*
* returns:
* XBoolean
* @xsl.usage advanced
*/
/**
* [NODETYPE_ROOT]
* No size or arguments.
*
* returns:
* XBoolean
* @xsl.usage advanced
*/
/**
* [NODETYPE_ANY]
* No size or arguments.
*
* returns:
* XBoolean
* @xsl.usage advanced
*/
/**
* [NODETYPE_ANY]
* No size or arguments.
*
* returns:
* XBoolean
* @xsl.usage advanced
*/
/**
* [FROM_stepType]
* [length, including predicates]
* [length of just the step, without the predicates]
* {node test}
* {predicates}?
*
* returns:
* XBoolean
* @xsl.usage advanced
*/
/** ancestor axes opcode. */
/** ancestor-or-self axes opcode. */
/** attribute axes opcode. */
/** children axes opcode. */
/** descendants axes opcode. */
/** descendants-of-self axes opcode. */
/** following axes opcode. */
/** following-siblings axes opcode. */
/** parent axes opcode. */
/** preceding axes opcode. */
/** preceding-sibling axes opcode. */
/** self axes opcode. */
/** namespace axes opcode. */
/** '/' axes opcode. */
/**
* For match patterns.
* @xsl.usage advanced
*/
/**
* For match patterns.
* @xsl.usage advanced
*/
/**
* For match patterns.
* @xsl.usage advanced
*/
/** The end of the axes types. */
/** The next free ID. Please keep this up to date. */
}