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

XSLTPUBFUN void XSLTCALL xsltUnparsedEntityURIFunction ( xmlXPathParserContextPtr  ctxt,
int  nargs 
)

xsltUnparsedEntityURIFunction: : the XPath Parser context : the number of arguments

Implement the unparsed-entity-uri() XSLT function string unparsed-entity-uri(string)

Definition at line 549 of file functions.c.

Referenced by xsltRegisterAllFunctions().

                                                                       {
    xmlXPathObjectPtr obj;
    xmlChar *str;

    if ((nargs != 1) || (ctxt->value == NULL)) {
        xsltGenericError(xsltGenericErrorContext,
        "unparsed-entity-uri() : expects one string arg\n");
    ctxt->error = XPATH_INVALID_ARITY;
    return;
    }
    obj = valuePop(ctxt);
    if (obj->type != XPATH_STRING) {
    obj = xmlXPathConvertString(obj);
    }

    str = obj->stringval;
    if (str == NULL) {
    valuePush(ctxt, xmlXPathNewString((const xmlChar *)""));
    } else {
    xmlEntityPtr entity;

    entity = xmlGetDocEntity(ctxt->context->doc, str);
    if (entity == NULL) {
        valuePush(ctxt, xmlXPathNewString((const xmlChar *)""));
    } else {
        if (entity->URI != NULL)
        valuePush(ctxt, xmlXPathNewString(entity->URI));
        else
        valuePush(ctxt, xmlXPathNewString((const xmlChar *)""));
    }
    }
    xmlXPathFreeObject(obj);
}

Generated on Sat May 26 2012 04:48:42 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.