ReactOS Fundraising Campaign 2012
 
€ 4,410 / € 30,000

Information | Donate

Home | Info | Community | Development | myReactOS | Contact Us

  1. Home
  2. Community
  3. Development
  4. myReactOS
  5. Fundraiser 2012

  1. Main Page
  2. Alphabetical List
  3. Data Structures
  4. Directories
  5. File List
  6. Data Fields
  7. Globals
  8. Related Pages

ReactOS Development > Doxygen

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

Process and xsl:message construct

Definition at line 427 of file xsltutils.c.

Referenced by xsltApplySequenceConstructor(), and xsltRegisterAllElement().

                                                                            {
    xmlGenericErrorFunc error = xsltGenericError;
    void *errctx = xsltGenericErrorContext;
    xmlChar *prop, *message;
    int terminate = 0;

    if ((ctxt == NULL) || (inst == NULL))
    return;

    if (ctxt->error != NULL) {
    error = ctxt->error;
    errctx = ctxt->errctx;
    }

    prop = xmlGetNsProp(inst, (const xmlChar *)"terminate", NULL);
    if (prop != NULL) {
    if (xmlStrEqual(prop, (const xmlChar *)"yes")) {
        terminate = 1;
    } else if (xmlStrEqual(prop, (const xmlChar *)"no")) {
        terminate = 0;
    } else {
        error(errctx,
        "xsl:message : terminate expecting 'yes' or 'no'\n");
        ctxt->state = XSLT_STATE_ERROR;
    }
    xmlFree(prop);
    }
    message = xsltEvalTemplateString(ctxt, node, inst);
    if (message != NULL) {
    int len = xmlStrlen(message);

    error(errctx, "%s", (const char *)message);
    if ((len > 0) && (message[len - 1] != '\n'))
        error(errctx, "\n");
    xmlFree(message);
    }
    if (terminate)
    ctxt->state = XSLT_STATE_STOPPED;
}

Generated on Sun May 27 2012 04:50:20 for ReactOS by doxygen 1.7.6.1

ReactOS is a registered trademark or a trademark of ReactOS Foundation in the United States and other countries.