ddc
|
XPath execution class. More...
#include <xpath_processor.h>
Public Types | |
enum | { e_no_error, e_error_syntax, e_error_overflow, e_error_execution, e_error_stack } |
Public Member Functions | |
xpath_processor (const TiXmlNode *XNp_source_tree, const char *cp_xpath_expr) | |
Constructor. More... | |
virtual | ~ xpath_processor () |
expression_result | er_compute_xpath () |
Compute an XPath expression. More... | |
TiXmlString | S_compute_xpath () |
Compute an XPath expression and return the result as a string. More... | |
int | i_compute_xpath () |
Compute an XPath expression and return the result as an integer. More... | |
bool | o_compute_xpath () |
double | d_compute_xpath () |
unsigned | u_compute_xpath_node_set () |
void | v_get_xpath_base (unsigned u_order, const TiXmlBase *&XBp_res, bool &o_attribute) |
Get one of the XML nodes from the resulting node set. Can only be used after a call to u_compute_xpath_node_set. More... | |
TiXmlNode * | XNp_get_xpath_node (unsigned u_order) |
Retrieves an XPath node from the node set. This assumes you know it's not an attribute. More... | |
TiXmlAttribute * | XAp_get_xpath_attribute (unsigned u_order) |
Retrieves an XPath attribute from the node set. This assumes you know it's an attribute. More... | |
Public Member Functions inherited from TinyXPath::xpath_stream | |
xpath_stream (const char *cp_in) | |
constructor More... | |
virtual | ~ xpath_stream () |
destructor More... | |
void | v_lexico_decode () |
Decode the byte stream, and construct the lexical list. More... | |
void | v_evaluate () |
Public Member Functions inherited from TinyXPath::byte_stream | |
byte_stream (const char *cp_in) | |
constructor More... | |
~ byte_stream () | |
destructor More... | |
_byte_ | b_top () |
Returns the byte on top. More... | |
_byte_ | b_pop () |
Consumes one byte. More... | |
bool | o_is_valid () |
true if there are still some byte to consume More... | |
unsigned | u_remain () |
number of bytes still to consume More... | |
_byte_ | b_forward (unsigned u_nb_char) |
peek a byte a little further down the stream More... | |
const _byte_ * | bp_get_backward (unsigned u_amount) |
get a byte backward pointer to the stream More... | |
Public Attributes | |
enum TinyXPath::xpath_processor:: { ... } | e_error |
Protected Member Functions | |
virtual void | v_action (xpath_construct, unsigned, unsigned, const char *) |
Callback from the XPath decoder : a rule has to be applied. More... | |
virtual int | i_get_action_counter () |
Internal use. Retrieves the current action counter. More... | |
void | v_execute_stack () |
Internal use. Executes the XPath expression. The executions starts at the end of the as_action_store list. More... | |
void | v_pop_one_action (xpath_construct &xc_action, unsigned &u_sub, unsigned &u_ref, TiXmlString &S_literal) |
Retrieves one quadruplet from the action placeholder. More... | |
void | v_execute_one (xpath_construct xc_rule, bool o_skip_only) |
Executes one XPath rule. More... | |
void | v_execute_absolute_path (unsigned u_action_position, bool o_with_rel, bool o_everywhere) |
Execute a full set of absolute/relative/relative/.. computation. More... | |
void | v_execute_step (int &i_relative_action, bool o_skip_only) |
One step execution. More... | |
bool | o_check_predicate (TiXmlElement *XEp_child, bool o_by_name) |
void | v_execute_function (TiXmlString &S_name, unsigned u_nb_arg, expression_result **erpp_arg) |
void | v_function_ceiling (unsigned u_nb_arg, expression_result **erpp_arg) |
XPath ceiling function. More... | |
void | v_function_concat (unsigned u_nb_arg, expression_result **erpp_arg) |
XPath concat function. More... | |
void | v_function_contains (unsigned u_nb_arg, expression_result **erpp_arg) |
XPath contains function. More... | |
void | v_function_count (unsigned u_nb_arg, expression_result **erpp_arg) |
XPath count function. More... | |
void | v_function_false (unsigned u_nb_arg, expression_result **erpp_arg) |
XPath false function. More... | |
void | v_function_floor (unsigned u_nb_arg, expression_result **erpp_arg) |
XPath floor function. More... | |
void | v_function_last (unsigned u_nb_arg, expression_result **erpp_arg) |
XPath last function. More... | |
void | v_function_name (unsigned u_nb_arg, expression_result **erpp_arg) |
XPath name function. More... | |
void | v_function_normalize_space (unsigned u_nb_arg, expression_result **erpp_arg) |
XPath normalize-space function. More... | |
void | v_function_not (unsigned u_nb_arg, expression_result **erpp_arg) |
XPath not function. More... | |
void | v_function_position (unsigned u_nb_arg, expression_result **erpp_arg) |
XPath position function. More... | |
void | v_function_starts_with (unsigned u_nb_arg, expression_result **erpp_arg) |
XPath starts-with function. More... | |
void | v_function_string_length (unsigned u_nb_arg, expression_result **erpp_arg) |
XPath sttring-length function. More... | |
void | v_function_substring (unsigned u_nb_arg, expression_result **erpp_arg) |
void | v_function_sum (unsigned u_nb_arg, expression_result **erpp_arg) |
void | v_function_text (unsigned u_nb_arg, expression_result **erpp_arg) |
XPath text function. More... | |
void | v_function_true (unsigned u_nb_arg, expression_result **erpp_arg) |
XPath true function. More... | |
void | v_function_equal (expression_result **erpp_arg) |
void | v_function_not_equal (expression_result **erpp_arg) |
This function is for internal use : evaluation of a non-equality expression. More... | |
void | v_function_equal_node_and_other (expression_result *erp_node, expression_result *erp_non) |
void | v_function_equal_2_node (expression_result *erp_node_set_, expression_result *erp_node_set_2) |
void | v_function_union (node_set &ns_1, node_set &ns_2) |
Union function. More... | |
void | v_function_minus (expression_result **erpp_arg) |
XPath - function. More... | |
void | v_function_plus (expression_result **erpp_arg) |
XPath + function. More... | |
void | v_function_or (expression_result **erpp_arg) |
XPath or function. More... | |
void | v_function_and (expression_result **erpp_arg) |
XPath and function. More... | |
void | v_function_relational (expression_result **erpp_arg, unsigned u_sub) |
XPath relational comparison function. More... | |
void | v_function_opposite () |
void | v_function_mult (expression_result **erpp_arg, unsigned u_sub) |
XPath * function (arithmetic) More... | |
void | v_order_tree () |
void | v_order_recurs (TiXmlNode *Np_base, size_t &i_current) |
void | v_push_int (int i_val, const char *cp_comment="") |
void | v_push_string (TiXmlString S_val) |
void | v_push_bool (bool o_val) |
void | v_push_double (double d_val) |
void | v_push_node_set (node_set *nsp_val) |
bool | o_pop_bool () |
int | i_pop_int () |
TiXmlString | S_pop_string () |
node_set | ns_pop_node_set () |
void | v_set_context (TiXmlElement *XEp_in, bool o_by_name) |
Set the current context node for predicate evaluations. More... | |
const TiXmlElement * | XEp_get_context () |
void | v_build_root () |
void | v_remove_root () |
Protected Attributes | |
xpath_stack | xs_stack |
action_store | as_action_store |
TiXmlElement * | XEp_root |
Root, above the XML tree given as parameter to the xpath_processor object. More... | |
const TiXmlElement * | XEp_context |
Current context. More... | |
expression_result | er_result |
The result of the XPath evaluation, for further node retrieving by v_get_xpath_base. More... | |
bool | o_is_context_by_name |
const TiXmlNode * | XNp_caller_parent |
const TiXmlNode * | XNp_caller_prev |
const TiXmlNode * | XNp_caller_next |
const TiXmlNode * | XNp_base |
Protected Attributes inherited from TinyXPath::xpath_stream | |
token_syntax_decoder * | tlp_list |
List of tokens. More... | |
XPath execution class.
xpath_processor::xpath_processor | ( | const TiXmlNode * | XNp_source_tree, |
const char * | cp_xpath_expr | ||
) |
Constructor.
xpath_processor constructor
XNp_source_tree | Source XML tree |
cp_xpath_expr | XPath expression |
References o_is_context_by_name, XEp_context, and XNp_base.
|
inlinevirtual |
References TIXML_STRING.
expression_result xpath_processor::er_compute_xpath | ( | ) |
Compute an XPath expression.
The executions stack need to contain 1 and only 1 element, otherwize it's not valid
References e_error, e_error_execution, e_error_overflow, e_error_stack, e_error_syntax, e_no_error, er_result, v_build_root(), TinyXPath::xpath_stream::v_evaluate(), v_execute_stack(), v_remove_root(), XEp_root, and xs_stack.
Referenced by d_compute_xpath(), i_compute_xpath(), o_compute_xpath(), S_compute_xpath(), and u_compute_xpath_node_set().
TiXmlString xpath_processor::S_compute_xpath | ( | ) |
Compute an XPath expression and return the result as a string.
References er_compute_xpath(), and TIXML_STRING.
int xpath_processor::i_compute_xpath | ( | ) |
Compute an XPath expression and return the result as an integer.
References er_compute_xpath().
bool xpath_processor::o_compute_xpath | ( | ) |
double xpath_processor::d_compute_xpath | ( | ) |
unsigned xpath_processor::u_compute_xpath_node_set | ( | ) |
Compute an XPath expression, and return the number of nodes in the resulting node set.
Returns 0 if the result is not a node set
References TinyXPath::e_node_set, er_compute_xpath(), and er_result.
void xpath_processor::v_get_xpath_base | ( | unsigned | u_order, |
const TiXmlBase *& | XBp_res, | ||
bool & | o_attrib | ||
) |
Get one of the XML nodes from the resulting node set. Can only be used after a call to u_compute_xpath_node_set.
u_order | Order of the node. Must be between 0 and the number of nodes - 1 |
XBp_res | Output node |
o_attrib | True if the output node is an attribute, false if it's a TiXmlNode |
References TinyXPath::e_node_set, and er_result.
Referenced by XAp_get_xpath_attribute(), and XNp_get_xpath_node().
TiXmlNode * xpath_processor::XNp_get_xpath_node | ( | unsigned | u_order | ) |
Retrieves an XPath node from the node set. This assumes you know it's not an attribute.
u_order | Order of the node. Must be between 0 and the number of nodes - 1 |
References v_get_xpath_base().
TiXmlAttribute * xpath_processor::XAp_get_xpath_attribute | ( | unsigned | u_order | ) |
Retrieves an XPath attribute from the node set. This assumes you know it's an attribute.
u_order | Order of the node. Must be between 0 and the number of nodes - 1 |
References v_get_xpath_base().
|
protectedvirtual |
Callback from the XPath decoder : a rule has to be applied.
xc_rule | XPath Rule |
u_sub | Rule sub number |
u_variable | Parameter, depends on the rule |
cp_literal | Input literal, depends on the rule |
Implements TinyXPath::xpath_stream.
References as_action_store.
|
protectedvirtual |
Internal use. Retrieves the current action counter.
Implements TinyXPath::xpath_stream.
References as_action_store.
|
protected |
Internal use. Executes the XPath expression. The executions starts at the end of the as_action_store list.
References as_action_store, v_execute_one(), and TinyXPath::xpath_expr.
Referenced by er_compute_xpath().
|
protected |
Retrieves one quadruplet from the action placeholder.
xc_action | Next rule on placeholder |
u_sub | Sub rule |
u_ref | Rule optional parameter |
S_literal | Rule optional string |
References as_action_store.
Referenced by v_execute_one(), and v_execute_step().
|
protected |
Executes one XPath rule.
Compute each argument, and store them in a temporary list
xc_rule | Rule number |
o_skip_only | True if we only need to skip rules and not act on the data stack |
References TinyXPath::e_node_set, i_pop_int(), ns_pop_node_set(), S_pop_string(), TIXML_STRING, v_execute_absolute_path(), v_execute_function(), v_execute_step(), v_function_and(), v_function_equal(), v_function_minus(), v_function_mult(), v_function_not_equal(), v_function_opposite(), v_function_or(), v_function_plus(), v_function_relational(), v_function_union(), v_pop_one_action(), v_push_double(), v_push_int(), v_push_string(), TinyXPath::xpath_absolute_location_path, TinyXPath::xpath_absolute_location_path_abbrev, TinyXPath::xpath_absolute_location_path_slash, TinyXPath::xpath_absolute_location_path_slash_rel, TinyXPath::xpath_additive_expr, TinyXPath::xpath_additive_expr_minus, TinyXPath::xpath_additive_expr_more_minus, TinyXPath::xpath_additive_expr_more_plus, TinyXPath::xpath_additive_expr_plus, TinyXPath::xpath_additive_expr_simple, TinyXPath::xpath_and_expr, TinyXPath::xpath_and_expr_and, TinyXPath::xpath_and_expr_simple, TinyXPath::xpath_argument, TinyXPath::xpath_axis_name, TinyXPath::xpath_axis_specifier, TinyXPath::xpath_axis_specifier_at, TinyXPath::xpath_axis_specifier_axis_name, TinyXPath::xpath_axis_specifier_empty, TinyXPath::xpath_equality_expr, TinyXPath::xpath_equality_expr_equal, TinyXPath::xpath_equality_expr_not_equal, TinyXPath::xpath_equality_expr_simple, TinyXPath::xpath_expr, TinyXPath::xpath_filter_expr, TinyXPath::xpath_filter_expr_predicate, TinyXPath::xpath_filter_expr_primary, TinyXPath::xpath_function_call, TinyXPath::xpath_location_path, TinyXPath::xpath_location_path_abs, TinyXPath::xpath_location_path_rel, TinyXPath::xpath_multiplicative_expr, TinyXPath::xpath_multiplicative_expr_div, TinyXPath::xpath_multiplicative_expr_mod, TinyXPath::xpath_multiplicative_expr_simple, TinyXPath::xpath_multiplicative_expr_star, TinyXPath::xpath_name_test, TinyXPath::xpath_name_test_ncname, TinyXPath::xpath_name_test_qname, TinyXPath::xpath_name_test_star, TinyXPath::xpath_node_test, TinyXPath::xpath_node_test_name_test, TinyXPath::xpath_node_test_pi, TinyXPath::xpath_node_test_pi_lit, TinyXPath::xpath_node_test_reserved_keyword, TinyXPath::xpath_or_expr, TinyXPath::xpath_or_expr_or, TinyXPath::xpath_or_expr_simple, TinyXPath::xpath_path_expr, TinyXPath::xpath_path_expr_2_slash, TinyXPath::xpath_path_expr_filter, TinyXPath::xpath_path_expr_location_path, TinyXPath::xpath_path_expr_slash, TinyXPath::xpath_predicate, TinyXPath::xpath_predicate_expr, TinyXPath::xpath_primary_expr, TinyXPath::xpath_primary_expr_function_call, TinyXPath::xpath_primary_expr_literal, TinyXPath::xpath_primary_expr_number, TinyXPath::xpath_primary_expr_paren_expr, TinyXPath::xpath_primary_expr_variable, TinyXPath::xpath_relational_expr, TinyXPath::xpath_relational_expr_gt, TinyXPath::xpath_relational_expr_gte, TinyXPath::xpath_relational_expr_lt, TinyXPath::xpath_relational_expr_lte, TinyXPath::xpath_relational_expr_simple, TinyXPath::xpath_relative_location_path, TinyXPath::xpath_relative_location_path_rel_double_slash_step, TinyXPath::xpath_relative_location_path_rel_step, TinyXPath::xpath_relative_location_path_step, TinyXPath::xpath_unary_expr, TinyXPath::xpath_unary_expr_minus, TinyXPath::xpath_unary_expr_simple, TinyXPath::xpath_union_expr, TinyXPath::xpath_union_expr_simple, TinyXPath::xpath_union_expr_union, TinyXPath::xpath_variable_reference, TinyXPath::xpath_xml_local_part, TinyXPath::xpath_xml_prefix, TinyXPath::xpath_xml_q_name, TinyXPath::xpath_xml_q_name_colon, TinyXPath::xpath_xml_q_name_simple, and xs_stack.
Referenced by o_check_predicate(), v_execute_stack(), and v_execute_step().
|
protected |
Execute a full set of absolute/relative/relative/.. computation.
u_action_position | Position of the placeholder after the rule |
o_with_rel | true if there is some relative path |
o_everywhere | true if it's a '//' path |
References as_action_store, TIXML_STRING, v_execute_step(), and TinyXPath::xpath_relative_location_path.
Referenced by v_execute_one().
|
protected |
One step execution.
Initialize the source node set if it's the first step of a path
i_relative_action | Path position : -1 if first in a '//' path, 0 if first in a '/' path, > 0 if followers |
References as_action_store, TiXmlNode::COMMENT, TiXmlNode::ELEMENT, i_pop_int(), TinyXPath::lex_ancestor, TinyXPath::lex_ancestor_or_self, TinyXPath::lex_attribute, TinyXPath::lex_child, TinyXPath::lex_comment, TinyXPath::lex_descendant, TinyXPath::lex_descendant_or_self, TinyXPath::lex_following, TinyXPath::lex_following_sibling, TinyXPath::lex_node, TinyXPath::lex_parent, TinyXPath::lex_preceding, TinyXPath::lex_preceding_sibling, TinyXPath::lex_self, TinyXPath::lex_text, o_check_predicate(), S_pop_string(), TiXmlNode::TEXT, TIXML_STRING, TinyXPath::node_set::u_get_nb_node_in_set(), v_execute_one(), v_pop_one_action(), v_push_node_set(), XEp_context, XEp_root, TinyXPath::xpath_axis_specifier, TinyXPath::xpath_node_test, TinyXPath::xpath_predicate, and xs_stack.
Referenced by v_execute_absolute_path(), and v_execute_one().
|
protected |
Spec extract :
A PredicateExpr is evaluated by evaluating the Expr and converting the result to a boolean. If the result is a number, the result will be converted to true if the number is equal to the context position and will be converted to false otherwise; if the result is not a number, then the result will be converted as if by a call to the boolean function. Thus a location path para[3] is equivalent to para[position()=3].
References TinyXPath::e_double, TinyXPath::e_int, TinyXPath::i_xml_cardinality(), v_execute_one(), v_set_context(), TinyXPath::xpath_predicate, and xs_stack.
Referenced by v_execute_step().
|
protected |
Execute an XPath function. The arguments are in normal order in erpp_arg
Calls one of the following :
S_name | Function name |
u_nb_arg | Nb of arguments |
erpp_arg | Argument list |
References v_function_ceiling(), v_function_concat(), v_function_contains(), v_function_count(), v_function_false(), v_function_floor(), v_function_last(), v_function_name(), v_function_normalize_space(), v_function_not(), v_function_position(), v_function_starts_with(), v_function_string_length(), v_function_substring(), v_function_sum(), v_function_text(), and v_function_true().
Referenced by v_execute_one().
|
protected |
XPath ceiling function.
u_nb_arg | Nb of arguments |
erpp_arg | Argument list |
References TinyXPath::e_bool, TinyXPath::e_double, TinyXPath::e_int, and v_push_int().
Referenced by v_execute_function().
|
protected |
XPath concat function.
u_nb_arg | Nb of arguments |
erpp_arg | Argument list |
References TIXML_STRING, and v_push_string().
Referenced by v_execute_function().
|
protected |
XPath contains function.
u_nb_arg | Nb of arguments |
erpp_arg | Argument list |
References TIXML_STRING, and v_push_bool().
Referenced by v_execute_function().
|
protected |
XPath count function.
u_nb_arg | Nb of arguments |
erpp_arg | Argument list |
References TinyXPath::e_node_set, and v_push_int().
Referenced by v_execute_function().
|
protected |
XPath false function.
u_nb_arg | Nb of arguments |
erpp_arg | Argument list |
References v_push_bool().
Referenced by v_execute_function().
|
protected |
XPath floor function.
u_nb_arg | Nb of arguments |
erpp_arg | Argument list |
References TinyXPath::e_bool, TinyXPath::e_double, TinyXPath::e_int, and v_push_int().
Referenced by v_execute_function().
|
protected |
XPath last function.
u_nb_arg | Nb of arguments |
erpp_arg | Argument list |
References TinyXPath::i_xml_family_size(), v_push_int(), XEp_context, and XEp_get_context().
Referenced by v_execute_function().
|
protected |
XPath name function.
u_nb_arg | Nb of arguments |
erpp_arg | Argument list |
References TinyXPath::e_node_set, Name, TIXML_STRING, and v_push_string().
Referenced by v_execute_function().
|
protected |
XPath normalize-space function.
u_nb_arg | Nb of arguments |
erpp_arg | Argument list |
References TinyXPath::S_remove_lead_trail(), TIXML_STRING, and v_push_string().
Referenced by v_execute_function().
|
protected |
XPath not function.
u_nb_arg | Nb of arguments |
erpp_arg | Argument list |
References v_push_bool().
Referenced by v_execute_function().
|
protected |
XPath position function.
u_nb_arg | Nb of arguments |
erpp_arg | Argument list |
References TinyXPath::i_xml_cardinality(), o_is_context_by_name, v_push_int(), XEp_context, and XEp_get_context().
Referenced by v_execute_function().
|
protected |
XPath starts-with function.
u_nb_arg | Nb of arguments |
erpp_arg | Argument list |
References TIXML_STRING, and v_push_bool().
Referenced by v_execute_function().
|
protected |
XPath sttring-length function.
u_nb_arg | Nb of arguments |
erpp_arg | Argument list |
References TIXML_STRING, and v_push_int().
Referenced by v_execute_function().
|
protected |
XPath substring function
Standard excerpt:
The substring function returns the substring of the first argument starting at the position specified in the second argument with length specified in the third argument. For example, substring("12345",2,3) returns "234". If the third argument is not specified, it returns the substring starting at the position specified in the second argument and continuing to the end of the string. For example, substring("12345",2) returns "2345".
u_nb_arg | Nb of arguments |
erpp_arg | Argument list |
References TIXML_STRING, and v_push_string().
Referenced by v_execute_function().
|
protected |
XPath sum function
Standard exerpt :
The sum function returns the sum, for each node in the argument node-set, of the result of converting the string-values of the node to a number.
u_nb_arg | Nb of arguments |
erpp_arg | Argument list |
References TinyXPath::e_node_set, v_push_double(), and v_push_int().
Referenced by v_execute_function().
|
protected |
XPath text function.
u_nb_arg | Nb of arguments |
erpp_arg | Argument list |
References TiXmlNode::TEXT, TIXML_STRING, v_push_string(), XEp_context, and XEp_get_context().
Referenced by v_execute_function().
|
protected |
XPath true function.
u_nb_arg | Nb of arguments |
erpp_arg | Argument list |
References v_push_bool().
Referenced by v_execute_function().
|
protected |
This function is for internal use : evaluation of an equality expression
Standard excerpt :
If both objects to be compared are node-sets, then the comparison will be true if and only if there is a node in the first node-set and a node in the second node-set such that the result of performing the comparison on the string-values of the two nodes is true.
If one object to be compared is a node-set and the other is a number, then the comparison will be true if and only if there is a node in the node-set such that the result of performing the comparison on the number to be compared and on the result of converting the string-value of that node to a number using the number function is true.
If one object to be compared is a node-set and the other is a string, then the comparison will be true if and only if there is a node in the node-set such that the result of performing the comparison on the string-value of the node and the other string is true.
If one object to be compared is a node-set and the other is a boolean, then the comparison will be true if and only if the result of performing the comparison on the boolean and on the result of converting the node-set to a boolean using the boolean function is true.
When neither object to be compared is a node-set and the operator is = or !=, then the objects are compared by converting them to a common type as follows and then comparing them.
References TinyXPath::e_bool, TinyXPath::e_double, TinyXPath::e_int, TinyXPath::e_node_set, v_function_equal_2_node(), v_function_equal_node_and_other(), and v_push_bool().
Referenced by v_execute_one(), and v_function_not_equal().
|
protected |
This function is for internal use : evaluation of a non-equality expression.
References o_pop_bool(), v_function_equal(), and v_push_bool().
Referenced by v_execute_one().
|
protected |
Utility function that evaluates the equality between a node set and a non-node set
Standard excerpt :
If one object to be compared is a node-set and the other is a number, then the comparison will be true if and only if there is a node in the node-set such that the result of performing the comparison on the number to be compared and on the result of converting the string-value of that node to a number using the number function is true.
If one object to be compared is a node-set and the other is a string, then the comparison will be true if and only if there is a node in the node-set such that the result of performing the comparison on the string-value of the node and the other string is true.
If one object to be compared is a node-set and the other is a boolean, then the comparison will be true if and only if the result of performing the comparison on the boolean and on the result of converting the node-set to a boolean using the boolean function is true.
References TinyXPath::e_bool, TinyXPath::e_double, TinyXPath::e_int, TinyXPath::e_string, and v_push_bool().
Referenced by v_function_equal().
|
protected |
Referenced by v_function_equal().
Union function.
References v_push_node_set().
Referenced by v_execute_one().
|
protected |
XPath - function.
References TinyXPath::e_double, v_push_double(), and v_push_int().
Referenced by v_execute_one().
|
protected |
XPath + function.
References TinyXPath::e_double, v_push_double(), and v_push_int().
Referenced by v_execute_one().
|
protected |
XPath or function.
References v_push_bool().
Referenced by v_execute_one().
|
protected |
XPath and function.
References v_push_bool().
Referenced by v_execute_one().
|
protected |
XPath relational comparison function.
References TinyXPath::e_double, v_push_bool(), TinyXPath::xpath_relational_expr_gt, TinyXPath::xpath_relational_expr_gte, TinyXPath::xpath_relational_expr_lt, and TinyXPath::xpath_relational_expr_lte.
Referenced by v_execute_one().
|
protected |
This function, because it only operates on one argument retrieves it himself from the stack
It computes the mathematical opposite
References TinyXPath::e_double, v_push_double(), v_push_int(), and xs_stack.
Referenced by v_execute_one().
|
protected |
XPath * function (arithmetic)
References TinyXPath::e_double, v_push_double(), v_push_int(), TinyXPath::xpath_multiplicative_expr_div, TinyXPath::xpath_multiplicative_expr_mod, and TinyXPath::xpath_multiplicative_expr_star.
Referenced by v_execute_one().
|
protected |
flag that says if the tree has been ordered already. This is a rather slow process, so we only do it if needed
Order the tree : assign an integer to all nodes based on the document order
Right now, tinyxml doesn't have a user value associated to attributes ... arrrgh. We order everything else, and will have to compute attributes order on demand
References v_order_recurs(), and XEp_root.
Referenced by v_build_root().
|
protected |
Recursive ordering of an XML tree according to XPath's document order.
The result is stored as an integer in the void * pointer managed by TiXmlNode::SetUserData / TiXmlNode::GetUserData
Referenced by v_order_tree().
|
inlineprotected |
References v_push_int().
Referenced by v_execute_one(), v_function_ceiling(), v_function_count(), v_function_floor(), v_function_last(), v_function_minus(), v_function_mult(), v_function_opposite(), v_function_plus(), v_function_position(), v_function_string_length(), v_function_sum(), and v_push_int().
|
inlineprotected |
References v_push_string().
Referenced by v_execute_one(), v_function_concat(), v_function_name(), v_function_normalize_space(), v_function_substring(), v_function_text(), and v_push_string().
|
inlineprotected |
References v_push_bool().
Referenced by v_function_and(), v_function_contains(), v_function_equal(), v_function_equal_node_and_other(), v_function_false(), v_function_not(), v_function_not_equal(), v_function_or(), v_function_relational(), v_function_starts_with(), v_function_true(), and v_push_bool().
|
inlineprotected |
References v_push_double().
Referenced by v_execute_one(), v_function_minus(), v_function_mult(), v_function_opposite(), v_function_plus(), v_function_sum(), and v_push_double().
|
inlineprotected |
References v_push_node_set().
Referenced by v_execute_step(), v_function_union(), and v_push_node_set().
|
inlineprotected |
References o_pop_bool().
Referenced by o_pop_bool(), and v_function_not_equal().
|
inlineprotected |
References i_pop_int().
Referenced by i_pop_int(), v_execute_one(), and v_execute_step().
|
inlineprotected |
References S_pop_string().
Referenced by S_pop_string(), v_execute_one(), and v_execute_step().
|
inlineprotected |
References ns_pop_node_set().
Referenced by ns_pop_node_set(), and v_execute_one().
|
protected |
Set the current context node for predicate evaluations.
XEp_in | Context node |
o_by_name | true if the current node search is by name, false if it's a * |
References o_is_context_by_name, and XEp_context.
Referenced by o_check_predicate().
|
inlineprotected |
Referenced by v_function_last(), v_function_position(), and v_function_text().
|
protected |
References v_order_tree(), XEp_context, XEp_root, XNp_base, XNp_caller_next, XNp_caller_parent, and XNp_caller_prev.
Referenced by er_compute_xpath().
|
protected |
Remove our fake root, and restore the original relationships of the node given to us as argument
References XEp_root, XNp_base, XNp_caller_next, XNp_caller_parent, and XNp_caller_prev.
Referenced by er_compute_xpath().
enum { ... } TinyXPath::xpath_processor::e_error |
Referenced by er_compute_xpath().
|
protected |
Referenced by er_compute_xpath(), o_check_predicate(), v_execute_one(), v_execute_step(), and v_function_opposite().
|
protected |
Referenced by i_get_action_counter(), v_action(), v_execute_absolute_path(), v_execute_stack(), v_execute_step(), and v_pop_one_action().
|
protected |
Root, above the XML tree given as parameter to the xpath_processor object.
Referenced by er_compute_xpath(), v_build_root(), v_execute_step(), v_order_tree(), and v_remove_root().
|
protected |
Current context.
Referenced by v_build_root(), v_execute_step(), v_function_last(), v_function_position(), v_function_text(), v_set_context(), and xpath_processor().
|
protected |
The result of the XPath evaluation, for further node retrieving by v_get_xpath_base.
Referenced by er_compute_xpath(), u_compute_xpath_node_set(), and v_get_xpath_base().
|
protected |
Referenced by v_function_position(), v_set_context(), and xpath_processor().
|
protected |
Referenced by v_build_root(), and v_remove_root().
|
protected |
Referenced by v_build_root(), and v_remove_root().
|
protected |
Referenced by v_build_root(), and v_remove_root().
|
protected |
Referenced by v_build_root(), v_remove_root(), and xpath_processor().