xsltutils

Name

xsltutils -- 

Synopsis



#define     TODO
#define     STRANGE
#define     IS_XSLT_ELEM                    (n)
#define     IS_XSLT_NAME                    (n, val)
xmlChar*    xsltGetNsProp                   (xmlNodePtr node,
                                             const xmlChar *name,
                                             const xmlChar *nameSpace);
extern      xmlGenericErrorFunc xsltGenericError;
extern      void *xsltGenericErrorContext;
extern      xmlGenericErrorFunc xsltGenericDebug;
extern      void *xsltGenericDebugContext;
void        xsltMessage                     (xsltTransformContextPtr ctxt,
                                             xmlNodePtr node,
                                             xmlNodePtr inst);
void        xsltSetGenericErrorFunc         (void *ctx,
                                             xmlGenericErrorFunc handler);
void        xsltSetGenericDebugFunc         (void *ctx,
                                             xmlGenericErrorFunc handler);
void        xsltDocumentSortFunction        (xmlNodeSetPtr list);
void        xsltDoSortFunction              (xsltTransformContextPtr ctxt,
                                             xmlNodePtr *sorts,
                                             int nbsorts);
int         xsltSaveResultTo                (xmlOutputBufferPtr buf,
                                             xmlDocPtr result,
                                             xsltStylesheetPtr style);
int         xsltSaveResultToFilename        (const char *URI,
                                             xmlDocPtr result,
                                             xsltStylesheetPtr style,
                                             int compression);
int         xsltSaveResultToFile            (FILE *file,
                                             xmlDocPtr result,
                                             xsltStylesheetPtr style);
int         xsltSaveResultToFd              (int fd,
                                             xmlDocPtr result,
                                             xsltStylesheetPtr style);

Description

Details

TODO

#define     TODO

macro to flag unimplemented blocks


STRANGE

#define     STRANGE

macro to flag that a problem was detected internally


IS_XSLT_ELEM()

#define     IS_XSLT_ELEM(n)

Checks that the element pertains to XSLt namespace

n : 


IS_XSLT_NAME()

#define     IS_XSLT_NAME(n, val)

Checks the value of an element in XSLT namespace

n : 
val : 


xsltGetNsProp ()

xmlChar*    xsltGetNsProp                   (xmlNodePtr node,
                                             const xmlChar *name,
                                             const xmlChar *nameSpace);

Similar to xmlGetNsProp() but with a slightly different semantic

Search and get the value of an attribute associated to a node This attribute has to be anchored in the namespace specified, or has no namespace and the element is in that namespace.

This does the entity substitution. This function looks in DTD attribute declaration for FIXED or default declaration values unless DTD use has been turned off.

node : the node
name : the attribute name
nameSpace : the URI of the namespace
Returns :the attribute value or NULL if not found. It's up to the caller to free the memory.


xsltGenericError

extern xmlGenericErrorFunc xsltGenericError;


xsltGenericErrorContext

extern void *xsltGenericErrorContext;


xsltGenericDebug

extern xmlGenericErrorFunc xsltGenericDebug;


xsltGenericDebugContext

extern void *xsltGenericDebugContext;


xsltMessage ()

void        xsltMessage                     (xsltTransformContextPtr ctxt,
                                             xmlNodePtr node,
                                             xmlNodePtr inst);

Process and xsl:message construct

ctxt : an XSLT processing context
node : The current node
inst : The node containing the message instruction


xsltSetGenericErrorFunc ()

void        xsltSetGenericErrorFunc         (void *ctx,
                                             xmlGenericErrorFunc handler);

Function to reset the handler and the error context for out of context error messages. This simply means that handler will be called for subsequent error messages while not parsing nor validating. And ctx will be passed as first argument to handler One can simply force messages to be emitted to another FILE * than stderr by setting ctx to this file handle and handler to NULL.

ctx : the new error handling context
handler : the new handler function


xsltSetGenericDebugFunc ()

void        xsltSetGenericDebugFunc         (void *ctx,
                                             xmlGenericErrorFunc handler);

Function to reset the handler and the error context for out of context error messages. This simply means that handler will be called for subsequent error messages while not parsing nor validating. And ctx will be passed as first argument to handler One can simply force messages to be emitted to another FILE * than stderr by setting ctx to this file handle and handler to NULL.

ctx : the new error handling context
handler : the new handler function


xsltDocumentSortFunction ()

void        xsltDocumentSortFunction        (xmlNodeSetPtr list);

reorder the current node list list accordingly to the document order

list : the node set


xsltDoSortFunction ()

void        xsltDoSortFunction              (xsltTransformContextPtr ctxt,
                                             xmlNodePtr *sorts,
                                             int nbsorts);

reorder the current node list accordingly to the set of sorting requirement provided by the arry of nodes.

ctxt : a XSLT process context
sorts : array of sort nodes
nbsorts : the number of sorts in the array


xsltSaveResultTo ()

int         xsltSaveResultTo                (xmlOutputBufferPtr buf,
                                             xmlDocPtr result,
                                             xsltStylesheetPtr style);

Save the result result obtained by applying the style stylesheet to an I/O output channel buf

buf : an output buffer
result : the result xmlDocPtr
style : the stylesheet
Returns :the number of byte written or -1 in case of failure.


xsltSaveResultToFilename ()

int         xsltSaveResultToFilename        (const char *URI,
                                             xmlDocPtr result,
                                             xsltStylesheetPtr style,
                                             int compression);

Save the result result obtained by applying the style stylesheet to a file or URL URL

URI : 
result : the result xmlDocPtr
style : the stylesheet
compression : the compression factor (0 - 9 included)
Returns :the number of byte written or -1 in case of failure.


xsltSaveResultToFile ()

int         xsltSaveResultToFile            (FILE *file,
                                             xmlDocPtr result,
                                             xsltStylesheetPtr style);

Save the result result obtained by applying the style stylesheet to an open FILE * I/O. This does not close the FILE file

file : a FILE * I/O
result : the result xmlDocPtr
style : the stylesheet
Returns :the number of byte written or -1 in case of failure.


xsltSaveResultToFd ()

int         xsltSaveResultToFd              (int fd,
                                             xmlDocPtr result,
                                             xsltStylesheetPtr style);

Save the result result obtained by applying the style stylesheet to an open file descriptor This does not close the descriptor.

fd : a file descriptor
result : the result xmlDocPtr
style : the stylesheet
Returns :the number of byte written or -1 in case of failure.