xpath_parser_ctxt(
NULL)
67 return "XPATH_EXPRESSION_OK";
69 return "XPATH_NUMBER_ERROR";
71 return "XPATH_UNFINISHED_LITERAL_ERROR";
73 return "XPATH_START_LITERAL_ERROR";
75 return "XPATH_VARIABLE_REF_ERROR";
77 return "XPATH_UNDEF_VARIABLE_ERROR";
79 return "XPATH_INVALID_PREDICATE_ERROR";
81 return "XPATH_EXPR_ERROR";
83 return "XPATH_UNCLOSED_ERROR";
85 return "XPATH_UNKNOWN_FUNC_ERROR";
87 return "XPATH_INVALID_OPERAND";
89 return "XPATH_INVALID_TYPE";
91 return "XPATH_INVALID_ARITY";
93 return "XPATH_INVALID_CTXT_SIZE";
95 return "XPATH_INVALID_CTXT_POSITION";
97 return "XPATH_MEMORY_ERROR";
99 return "XPTR_SYNTAX_ERROR";
101 return "XPTR_RESOURCE_ERROR";
103 return "XPTR_SUB_RESOURCE_ERROR";
105 return "XPATH_UNDEF_PREFIX_ERROR";
107 return "XPATH_ENCODING_ERROR";
109 return "XPATH_INVALID_CHAR_ERROR";
111 return "XPATH_INVALID_CTXT";
124pimpl_(new
impl::extension_function_impl)
134pimpl_(new
impl::extension_function_impl)
150other.pimpl_ =
NULL;
156 if(
this!= &other) {
160other.pimpl_ =
NULL;
169 "out of XSLT context.");
178 std::stringmessage(
"Extension function error: "+
189 "out of XSLT context.");
191xsltTransformContextPtr xslt_ctxt =
193xsltTransformError(xslt_ctxt, xslt_ctxt->style,
NULL,
"%s",
error);
200 throw xslt::exception(
"Setting XSLT extension function return value " 201 "out of XSLT context.");
203xmlXPathObjectPtr
object=
204 reinterpret_cast<xmlXPathObjectPtr
>(ret_val.
get_object());
205 if(
object==
NULL)
209xsltTransformContextPtr xslt_ctxt =
223 if(object->type == XPATH_NODESET ||
224object->type == XPATH_XSLT_TREE) {
226 object->boolval = 0;
227 for(
intk = 0; k <
object->nodesetval->nodeNr; ++k)
230object->nodesetval->nodeTab[k]);
This exception class is thrown by xmlwrapp for all runtime XSLT-related errors.
The XSLT extension function object is used to be a base class for the user provided XSLT functions.
virtual ~extension_function()
Destroy extension function object and clean the memory up.
extension_function & operator=(const extension_function &other)
Create a copy of the extension function object.
extension_function()
Create a new extension function.
void set_return_value(const xpath_object &ret_val)
Set the extension function return value.
void report_error(const char *error)
Report an error to the XSLT processor.
impl::extension_function_impl * pimpl_
static bool get_allow_extension_functions_leak(void)
Provides the current setting of the extension functions memory management.
The xslt::xpath_object class is used to store extension function arguments and return values.
bool get_from_xslt(void) const
void * get_object(void) const
void revoke_ownership(void) const
XSLT extension function object.
This file contains definition of the xslt::impl::extension_function_impl class.
static std::string convert_error_code(xpath_error error)
xpath_error
XPath error which could be reported by a user XSLT extension function.
@ xptr_sub_resource_error
@ xpath_invalid_char_error
@ xpath_unknown_func_error
@ xpath_undef_variable_error
@ xpath_undef_prefix_error
@ xpath_variable_ref_error
@ xpath_invalid_predicate_error
@ xpath_invalid_ctxt_size
@ xpath_start_literal_error
@ xpath_invalid_ctxt_position
@ xpath_unfinished_literal_error
xmlXPathParserContextPtr xpath_parser_ctxt
extension_function_impl()
std::vector< xmlNodePtr > nodes_to_free_
This file contains definition of the xslt::impl::stylesheet_impl class.
This file contains the definition of the xslt::exception class.
This file contains the definition of the xslt::init class.
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4