JavaScript-1.5 Reference

JS_GetUCProperty Function

Summary

Finds a specified, Unicode-encoded property and retrieves its value.

Syntax

JSBool JS_GetUCProperty(JSContext *cx, JSObject *obj,
    const jschar *name, size_t namelen, jsval *vp);
NameTypeDescription
cxJSContext *Pointer to a JS context from which to derive runtime information.
objJSObject *Object to search on for the property.
nameconst jschar *Name of the property to look up.
namelensize_tLength, in bytes of the the property name to look up.
vpjsval *Pointer to a variable into which to store the current value of the property if it exists. If not, vp is set to JSVAL_VOID.

Description

JS_GetUCProperty examines a specified JS object, obj, its scope and prototype links, for a property named name. namelen indicates the size, in bytes, of name. If the property is not defined on the object in its scope, or in its prototype links, vp is set to JSVAL_VOID.

If the property exists, JS_GetUCProperty sets vp to the current value of the property, and returns JS_TRUE. If an error occurs during the search, JS_GetUCProperty returns JS_FALSE, and vp is undefined.

See Also

Groups [ Function ]
Documents [ LXR ID Search ]
Entries [ JSVAL_VOID | JS_AliasProperty | JS_DefineProperty | JS_DefinePropertyWithTinyId | JS_DefineUCProperty | JS_DefineUCPropertyWithTinyID | JS_DeleteProperty | JS_DeleteProperty2 | JS_DeleteUCProperty2 | JS_GetProperty | JS_LookupProperty | JS_PropertyStub | JS_SetProperty | JS_SetUCProperty ]

This page was generated by APIDOC