JavaScript-1.5 Reference

JSConstDoubleSpec Data Structure

Summary

Describes a double value and assigns it a name.

Syntax

struct JSConstDoubleSpec {
    jsdouble dval;
    const char *name;
    uint8 flags;
    uint8 spare[3];
};
NameTypeDescription
dvaljsdoubleValue for the double.
nameconst char *Name to assign the double.
flagsuint8Attributes for the double. Currently these can be 0 or more of the following values OR'd:
JSPROP_ENUMERATE: property is visible in for loops.
JSPROP_READONLY: property is read-only.
JSPROP_PERMANENT: property cannot be deleted.
JSPROP_EXPORTED: property can be exported outside its object.
JSPROP_INDEX: property is actually an array element.
spareuint8Reserved for future use.

Description

JSConstDoubleSpecs is typically used to define a set of double values that are assigned as properties to an object using JS_DefineConstDoubles. JS_DefineConstDoubles creates one or more double properties for a specified object.

JS_DefineConstDoubles takes an argument that is a pointer to an array of JSConstDoubleSpecs. Each array element defines a single property name and property value to create. The last element of the array must contain zero-valued values. JS_DefineConstDoubles creates one property for each non-zero element in the array.

See Also

Groups [ Data Structure ]
Documents [ LXR ID Search ]
Entries [ DOUBLE_TO_JSVAL | JSPROP_ENUMERATE | JSPROP_EXPORTED | JSPROP_INDEX | JSPROP_PERMANENT | JSPROP_READONLY | JSVAL_IS_DOUBLE | JSVAL_TO_DOUBLE | JS_DefineConstDoubles | JS_NewDouble | JS_NewDoubleValue | JS_ValueToNumber ]

This page was generated by APIDOC