JSValue jsXPathExceptionMessage(ExecState* exec, JSValue slotBase, const Identifier&)
{
    JSXPathException* castedThis = static_cast<JSXPathException*>(asObject(slotBase));
    UNUSED_PARAM(exec);
    XPathException* imp = static_cast<XPathException*>(castedThis->impl());
    JSValue result = jsString(exec, imp->message());
    return result;
}
示例#2
0
EncodedJSValue JSC_HOST_CALL jsXPathExceptionPrototypeFunctionToString(ExecState* exec)
{
    JSValue thisValue = exec->hostThisValue();
    if (!thisValue.inherits(&JSXPathException::s_info))
        return throwVMTypeError(exec);
    JSXPathException* castedThis = static_cast<JSXPathException*>(asObject(thisValue));
    XPathException* imp = static_cast<XPathException*>(castedThis->impl());


    JSC::JSValue result = jsString(exec, imp->toString());
    return JSValue::encode(result);
}