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_GetPropertyAttributes (Function)
Summary:     Retrieves the attributes of a specified property.
Syntax:
JSBool JS_GetPropertyAttributes(JSContext *cx, JSObject *obj,
const char *name, uintN *attrsp, JSBool *foundp);

     Argument     Type     Description
     cx     JSContext *     Pointer to a JS context from which to derive runtime information.
                 
     obj     JSObject *     Object from which to retrieve property attributes.
                 
     name     const char *     Name of the property from which to retrieve attributes.
                 
     uintN     attrsp *     Pointer to the storage area into which to place retrieves attributes.
                 
     foundp     JSBool *     Flag indicating whether or not the specified property was located.
                 
Description:
JS_GetPropertyAttributes retrieves the attributes for a specified property, namecx is the context, and obj is a pointer to the object that owns the property. attrsp is a pointer to the unsigned integer storage area into which to retrieve the attributes.

If JS_GetPropertyAttributes cannot locate an object with the specified property, it returns JS_FALSE, and both attrsp and foundp are undefined.

If the specified property or the specified object does not exist, foundp is set to JS_FALSE. If the property exists, but belongs to another object, JS_GetPropertyAttributes then returns JS_FALSE, and attrsp is undefined. If the property exists and it belongs to the object you specify, then foundp is set to JS_TRUE. If JS_GetPropertyAttributes can actually read the current property values, it returns JS_TRUE. Otherwise, it returns JS_FALSE.


See also:
JS_SetPropertyAttributes

[sh-index] Back to list of manuals