public final class JSNumber extends JSPrimitive implements JSConstructorFactory.WithFunctions
usesOrdinaryGetOwnPropertyJSConstructorFactory.Default, JSConstructorFactory.WithFunctions, JSConstructorFactory.WithFunctionsAndSpecies| Modifier and Type | Field and Description |
|---|---|
static com.oracle.truffle.api.strings.TruffleString |
CLASS_NAME |
static JSNumber |
INSTANCE |
static com.oracle.truffle.api.strings.TruffleString |
PROTOTYPE_NAME |
static com.oracle.truffle.api.strings.TruffleString |
TYPE_NAME |
GET_SYMBOL_SPECIES_NAME| Modifier and Type | Method and Description |
|---|---|
static JSNumberObject |
create(JSContext context,
JSRealm realm,
JSDynamicObject proto,
Number value) |
static JSNumberObject |
create(JSContext context,
JSRealm realm,
Number value) |
static JSConstructor |
createConstructor(JSRealm realm) |
JSDynamicObject |
createPrototype(JSRealm realm,
JSFunctionObject ctor) |
void |
fillConstructor(JSRealm realm,
JSDynamicObject constructor) |
com.oracle.truffle.api.strings.TruffleString |
getBuiltinToStringTag(JSDynamicObject object)
Returns builtinTag from step 14 of ES6+ 19.1.3.6.
|
com.oracle.truffle.api.strings.TruffleString |
getClassName() |
com.oracle.truffle.api.strings.TruffleString |
getClassName(JSDynamicObject object)
The [[Class]] internal property.
|
JSDynamicObject |
getIntrinsicDefaultProto(JSRealm realm)
Allows invokevirtual of this method instead of invokeinterface.
|
static boolean |
isJSNumber(Object obj) |
com.oracle.truffle.api.object.Shape |
makeInitialShape(JSContext context,
JSDynamicObject prototype) |
com.oracle.truffle.api.strings.TruffleString |
toDisplayStringImpl(JSDynamicObject obj,
boolean allowSideEffects,
ToDisplayStringFormat format,
int depth)
A more informative toString variant, mainly used for error messages.
|
static Number |
valueOf(JSDynamicObject obj) |
getHelper, getMethodHelpercheckProtoCycle, createSymbolSpeciesGetterFunction, defineOwnProperty, delete, delete, deletePropertyDefault, getHelper, getOwnHelper, getOwnHelper, getOwnProperty, getOwnPropertyKeys, getPrototypeOf, hasOnlyShapeProperties, hasOwnProperty, hasOwnProperty, hasProperty, hasProperty, invokeAccessorPropertySetter, isExtensible, ordinaryGetOwnProperty, ordinaryGetOwnPropertyIntl, ordinaryIsExtensible, ordinaryOwnPropertyKeys, ordinaryOwnPropertyKeys, ordinaryOwnPropertyKeysSlow, ordinarySet, ordinarySetIndex, ordinarySetWithReceiver, performOrdinarySetWithOwnDescriptor, preventExtensions, preventExtensionsImpl, putConstructorSpeciesGetter, set, set, setIntegrityLevel, setIntegrityLevelFast, setPropertySlow, setPrototypeOf, testIntegrityLevel, testIntegrityLevelFast, toString, usesOrdinaryGetOwnProperty, usesOrdinaryIsExtensibledefaultToString, filterOwnPropertyKeys, formatToString, get, get, getToStringTag, isInstance, isInstance, isInstance, isInstance, ownPropertyKeys, testIntegrityLevelDefaultclone, equals, getClass, hashCode, notify, notifyAll, wait, wait, waitcreateConstructorAndPrototypecreateConstructorObjectpublic static final com.oracle.truffle.api.strings.TruffleString TYPE_NAME
public static final com.oracle.truffle.api.strings.TruffleString CLASS_NAME
public static final com.oracle.truffle.api.strings.TruffleString PROTOTYPE_NAME
public static final JSNumber INSTANCE
public static JSNumberObject create(JSContext context, JSRealm realm, Number value)
public static JSNumberObject create(JSContext context, JSRealm realm, JSDynamicObject proto, Number value)
public static Number valueOf(JSDynamicObject obj)
public JSDynamicObject createPrototype(JSRealm realm, JSFunctionObject ctor)
createPrototype in interface JSConstructorFactorypublic com.oracle.truffle.api.object.Shape makeInitialShape(JSContext context, JSDynamicObject prototype)
makeInitialShape in class JSClasspublic void fillConstructor(JSRealm realm, JSDynamicObject constructor)
fillConstructor in interface JSConstructorFactorypublic static JSConstructor createConstructor(JSRealm realm)
public static boolean isJSNumber(Object obj)
public com.oracle.truffle.api.strings.TruffleString getClassName()
getClassName in interface JSConstructorFactorypublic com.oracle.truffle.api.strings.TruffleString getClassName(JSDynamicObject object)
JSClassgetClassName in class JSClassobject - object to be usedpublic com.oracle.truffle.api.strings.TruffleString getBuiltinToStringTag(JSDynamicObject object)
JSClassgetBuiltinToStringTag in class JSNonProxyobject - object to be usedJSClass.defaultToString(JSDynamicObject)public com.oracle.truffle.api.strings.TruffleString toDisplayStringImpl(JSDynamicObject obj, boolean allowSideEffects, ToDisplayStringFormat format, int depth)
JSClasstoDisplayStringImpl in class JSNonProxyformat - formatting parametersdepth - current nesting depthpublic JSDynamicObject getIntrinsicDefaultProto(JSRealm realm)
JSClassPrototypeSupplier.getIntrinsicDefaultProto in interface PrototypeSuppliergetIntrinsicDefaultProto in class JSClassPrototypeSupplier.getIntrinsicDefaultProto(com.oracle.truffle.js.runtime.JSRealm)