ddc
Public Member Functions | Public Attributes | Protected Attributes | List of all members
TinyXPath::expression_result Class Reference

Class holding the result of an expression (e_expression_type) More...

#include <xpath_expression.h>

Inheritance diagram for TinyXPath::expression_result:
Inheritance graph
[legend]
Collaboration diagram for TinyXPath::expression_result:
Collaboration graph
[legend]

Public Member Functions

 expression_result ()
 Dummy constructor. More...
 
 expression_result (const expression_result &er_2)
 Copy constructor. More...
 
expression_resultoperator= (const expression_result &er_2)
 
void v_set_bool (bool o_in)
 Set expression_result to a bool. More...
 
void v_set_int (int i_in)
 Set expression_result to an int. More...
 
void v_set_string (const char *cp_in)
 Set expression_result to a string. More...
 
void v_set_string (TiXmlString S_in)
 Set expression_result to a string. More...
 
void v_set_double (double d_in)
 Set expression_result to a double. More...
 
void v_set_comment (const char *cp_in)
 Set the comment associated with a stack element. This is for debuging. More...
 
int i_get_int ()
 Get the expression_result as an int. More...
 
TiXmlString S_get_string ()
 Get the expression_result as a string. More...
 
const char * cp_get_string ()
 Get the expression_result as a string. More...
 
bool o_get_bool ()
 
double d_get_double ()
 Get the expression_result as a double. More...
 
void v_set_node_set (node_set *nsp_source)
 Set the expression_result as a node set. More...
 
void v_set_node_set (TiXmlNode *XNp_root)
 Set the expression_result as a node set. More...
 
void v_set_node_set (TiXmlNode *XNp_root, const char *cp_lookup)
 Set the expression_result as a node set. More...
 
void v_set_node_set_recursive (TiXmlNode *XNp_root)
 Set the expression_result as a node set. More...
 
void v_set_node_set_recursive (TiXmlNode *XNp_root, const char *cp_lookup)
 Set the expression_result as a node set. More...
 
void v_set_node_set ()
 Set the expression_result as an empty node set. More...
 
node_setnsp_get_node_set ()
 Get the expression_result as a node set. More...
 

Public Attributes

e_expression_type e_type
 expression type More...
 

Protected Attributes

TiXmlString S_content
 String content. More...
 
bool o_content
 bool content More...
 
int i_content
 integer content More...
 
double d_content
 double content More...
 
node_set ns_set
 node set content More...
 

Detailed Description

Class holding the result of an expression (e_expression_type)

Constructor & Destructor Documentation

◆ expression_result() [1/2]

TinyXPath::expression_result::expression_result ( )
inline

Dummy constructor.

References TinyXPath::e_invalid.

◆ expression_result() [2/2]

TinyXPath::expression_result::expression_result ( const expression_result er_2)
inline

Copy constructor.

Member Function Documentation

◆ operator=()

expression_result& TinyXPath::expression_result::operator= ( const expression_result er_2)
inline

◆ v_set_bool()

void TinyXPath::expression_result::v_set_bool ( bool  o_in)
inline

Set expression_result to a bool.

References TinyXPath::e_bool.

Referenced by TinyXPath::xpath_stack::v_push_bool().

Here is the caller graph for this function:

◆ v_set_int()

void TinyXPath::expression_result::v_set_int ( int  i_in)
inline

Set expression_result to an int.

References TinyXPath::e_int.

Referenced by TinyXPath::xpath_stack::v_push_int().

Here is the caller graph for this function:

◆ v_set_string() [1/2]

void TinyXPath::expression_result::v_set_string ( const char *  cp_in)
inline

Set expression_result to a string.

References TinyXPath::e_string.

Referenced by TinyXPath::xpath_stack::v_push_string().

Here is the caller graph for this function:

◆ v_set_string() [2/2]

void TinyXPath::expression_result::v_set_string ( TiXmlString  S_in)
inline

Set expression_result to a string.

References TinyXPath::e_string.

◆ v_set_double()

void TinyXPath::expression_result::v_set_double ( double  d_in)
inline

Set expression_result to a double.

References TinyXPath::e_double.

Referenced by TinyXPath::xpath_stack::v_push_double().

Here is the caller graph for this function:

◆ v_set_comment()

void TinyXPath::expression_result::v_set_comment ( const char *  cp_in)
inline

Set the comment associated with a stack element. This is for debuging.

References i_get_int(), S_get_string(), and TIXML_STRING.

Referenced by TinyXPath::xpath_stack::v_push_int().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ i_get_int()

int TinyXPath::expression_result::i_get_int ( )

Get the expression_result as an int.

References d_content, TinyXPath::e_bool, TinyXPath::e_double, TinyXPath::e_int, e_type, i_content, o_content, and S_get_string().

Referenced by TinyXPath::xpath_stack::i_pop_int(), TinyXPath::xpath_stack::i_top_int(), S_get_string(), and v_set_comment().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ S_get_string()

TiXmlString TinyXPath::expression_result::S_get_string ( )

◆ cp_get_string()

const char* TinyXPath::expression_result::cp_get_string ( )
inline

Get the expression_result as a string.

References d_get_double(), TinyXPath::e_string, and o_get_bool().

Here is the call graph for this function:

◆ o_get_bool()

bool TinyXPath::expression_result::o_get_bool ( )

Get the expression_result as a bool
The boolean function converts its argument to a boolean as follows:

  • a number is true if and only if it is neither positive or negative zero nor NaN
  • a node-set is true if and only if it is non-empty
  • a string is true if and only if its length is non-zero
  • an object of a type other than the four basic types is converted to a boolean in a way that is dependent on that type

References d_content, d_get_double(), TinyXPath::e_bool, TinyXPath::e_double, TinyXPath::e_int, TinyXPath::e_invalid, TinyXPath::e_node_set, TinyXPath::e_string, e_type, i_content, ns_set, nsp_get_node_set(), o_content, and S_content.

Referenced by cp_get_string(), TinyXPath::xpath_stack::o_pop_bool(), and S_get_string().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ d_get_double()

double TinyXPath::expression_result::d_get_double ( )

Get the expression_result as a double.

References d_content, TinyXPath::e_bool, TinyXPath::e_double, TinyXPath::e_int, e_type, i_content, o_content, and S_get_string().

Referenced by cp_get_string(), o_get_bool(), and S_get_string().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ v_set_node_set() [1/4]

void TinyXPath::expression_result::v_set_node_set ( node_set nsp_source)
inline

Set the expression_result as a node set.

References TinyXPath::e_node_set.

◆ v_set_node_set() [2/4]

void TinyXPath::expression_result::v_set_node_set ( TiXmlNode XNp_root)
inline

Set the expression_result as a node set.

References TinyXPath::e_node_set.

◆ v_set_node_set() [3/4]

void TinyXPath::expression_result::v_set_node_set ( TiXmlNode XNp_root,
const char *  cp_lookup 
)
inline

Set the expression_result as a node set.

References TinyXPath::e_node_set.

◆ v_set_node_set_recursive() [1/2]

void TinyXPath::expression_result::v_set_node_set_recursive ( TiXmlNode XNp_root)
inline

Set the expression_result as a node set.

References TinyXPath::e_node_set.

◆ v_set_node_set_recursive() [2/2]

void TinyXPath::expression_result::v_set_node_set_recursive ( TiXmlNode XNp_root,
const char *  cp_lookup 
)
inline

Set the expression_result as a node set.

References TinyXPath::e_node_set.

◆ v_set_node_set() [4/4]

void TinyXPath::expression_result::v_set_node_set ( )
inline

Set the expression_result as an empty node set.

References TinyXPath::e_node_set.

Referenced by TinyXPath::xpath_stack::v_push_node_set().

Here is the caller graph for this function:

◆ nsp_get_node_set()

node_set* TinyXPath::expression_result::nsp_get_node_set ( )
inline

Get the expression_result as a node set.

References ns_set.

Referenced by TinyXPath::xpath_stack::ns_pop_node_set(), o_get_bool(), and S_get_string().

Here is the caller graph for this function:

Member Data Documentation

◆ S_content

TiXmlString TinyXPath::expression_result::S_content
protected

String content.

Referenced by o_get_bool(), operator=(), and S_get_string().

◆ o_content

bool TinyXPath::expression_result::o_content
protected

bool content

Referenced by d_get_double(), i_get_int(), o_get_bool(), and operator=().

◆ i_content

int TinyXPath::expression_result::i_content
protected

integer content

Referenced by d_get_double(), i_get_int(), o_get_bool(), and operator=().

◆ d_content

double TinyXPath::expression_result::d_content
protected

double content

Referenced by d_get_double(), i_get_int(), o_get_bool(), and operator=().

◆ ns_set

node_set TinyXPath::expression_result::ns_set
protected

node set content

Referenced by nsp_get_node_set(), o_get_bool(), and operator=().

◆ e_type

e_expression_type TinyXPath::expression_result::e_type

expression type

Referenced by d_get_double(), i_get_int(), o_get_bool(), operator=(), and S_get_string().


The documentation for this class was generated from the following files: