AcornSearch - Acorn and RISC OS information searching
RISC OS Search
containing
"Nutty quip goes here!"
Home  |  About  |  Filebase Archive  |  StrongHelp Manuals  |  Newsgroups  |  Module Database
Entry:     JS_LookupElement (Function)
Summary:     Determines if a specified element or numeric property exists.
Syntax:
JSBool JS_LookupElement(JSContext *cx, JSObject *obj,
jsint index, jsval *vp);

     Argument     Type     Description
     cx     JSContext *     Pointer to a JS context from which to derive runtime information.
                 
     obj     JSObject *     Object to search on for the element.
                 
     index     jsint     Index number of the element to look up.
                 
     vp     jsval *     Pointer to a variable into which to store the current value of the element if it has a value. If not, vp is set to JSVAL_VOID.
                 
Description:
JS_LookupElement examines a specified JS object, obj, for an element or numeric property numbered index. If the element exists, vp is set either to the current value of the property if it has a value, or to JSVAL_VOID if it does not, and JS_LookupElement returns JS_TRUE. On error, such as running out of memory during the search, JS_LookupElement returns JS_FALSE, and vp is undefined.


See also:
JS_AliasElement
JS_DefineElement
JS_DeleteElement
JS_GetArrayLength
JS_GetElement
JS_IsArrayObject
JS_NewArrayObject
JS_SetArrayLength
JS_SetElement

[sh-index] Back to list of manuals