Obsolete since JSAPI 8
This feature is obsolete. Although it may still work in some browsers, its use is discouraged since it could be removed at any time. Try to avoid using it.
Determines if an object has an array length property.
||Pointer to a JS context from which to derive runtime information. Requires request. In a
||Array object to get the length of.|
||Out parameter. On success,
JS_HasArrayLength determines if an object,
obj, has a
length property. If the property exists,
JS_HasArrayLength stores the current value of the property in
*lengthp receives the current value of the
length property. On failure,
JS_FALSE, and the value left in
*lengthp is undefined.
This function differs from
JS_GetArrayLength in the treatment of errors and unusual cases, like when an object's
length is negative or not a number. This function may return
JS_FALSE without having reported any error or exception.