Package me.topchetoeu.j2s.runtime.values
Class Value
java.lang.Object
me.topchetoeu.j2s.runtime.values.Value
- Direct Known Subclasses:
ObjectValue
,PrimitiveValue
,UserValue
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final me.topchetoeu.j2s.common.Key<ObjectValue>
static final me.topchetoeu.j2s.common.Key<ObjectValue>
static final me.topchetoeu.j2s.common.Key<ObjectValue>
static final me.topchetoeu.j2s.common.Key<ObjectValue>
static final me.topchetoeu.j2s.common.Key<Value>
static final me.topchetoeu.j2s.common.Key<ObjectValue>
static final me.topchetoeu.j2s.common.Key<ObjectValue>
static final VoidValue
static final me.topchetoeu.j2s.common.Key<ObjectValue>
static final me.topchetoeu.j2s.common.Key<ObjectValue>
static final me.topchetoeu.j2s.common.Key<ObjectValue>
static final me.topchetoeu.j2s.common.Key<ObjectValue>
static final me.topchetoeu.j2s.common.Key<ObjectValue>
static final me.topchetoeu.j2s.common.Key<ObjectValue>
static final me.topchetoeu.j2s.common.Key<ObjectValue>
static final me.topchetoeu.j2s.common.Key<ObjectValue>
static final VoidValue
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic final Value
static final NumberValue
static final NumberValue
bitwiseNot
(me.topchetoeu.j2s.common.Environment env, Value a) void
void
callWithAsync
(me.topchetoeu.j2s.common.Environment env, Iterable<? extends Value> it, boolean async) final Value
constructNoSelf
(me.topchetoeu.j2s.common.Environment env, Value... args) final boolean
defineOwnField
(me.topchetoeu.j2s.common.Environment env, double key, Value val) final boolean
defineOwnField
(me.topchetoeu.j2s.common.Environment env, double key, Value val, Boolean writable, Boolean enumerable, Boolean configurable) final boolean
defineOwnField
(me.topchetoeu.j2s.common.Environment env, int key, Value val) final boolean
defineOwnField
(me.topchetoeu.j2s.common.Environment env, int key, Value val, Boolean writable, Boolean enumerable, Boolean configurable) final boolean
defineOwnField
(me.topchetoeu.j2s.common.Environment env, String key, Value val) final boolean
defineOwnField
(me.topchetoeu.j2s.common.Environment env, String key, Value val, Boolean writable, Boolean enumerable, Boolean configurable) final boolean
defineOwnField
(me.topchetoeu.j2s.common.Environment env, KeyCache key, Value val) abstract boolean
defineOwnField
(me.topchetoeu.j2s.common.Environment env, KeyCache key, Value val, Boolean writable, Boolean enumerable, Boolean configurable) final boolean
defineOwnField
(me.topchetoeu.j2s.common.Environment env, Value key, Value val) final boolean
defineOwnField
(me.topchetoeu.j2s.common.Environment env, Value key, Value val, Boolean writable, Boolean enumerable, Boolean configurable) final boolean
defineOwnProperty
(me.topchetoeu.j2s.common.Environment env, double key, Optional<FunctionValue> get, Optional<FunctionValue> set, Boolean enumerable, Boolean configurable) final boolean
defineOwnProperty
(me.topchetoeu.j2s.common.Environment env, int key, Optional<FunctionValue> get, Optional<FunctionValue> set, Boolean enumerable, Boolean configurable) final boolean
defineOwnProperty
(me.topchetoeu.j2s.common.Environment env, String key, Optional<FunctionValue> get, Optional<FunctionValue> set, Boolean enumerable, Boolean configurable) abstract boolean
defineOwnProperty
(me.topchetoeu.j2s.common.Environment env, KeyCache key, Optional<FunctionValue> get, Optional<FunctionValue> set, Boolean enumerable, Boolean configurable) final boolean
defineOwnProperty
(me.topchetoeu.j2s.common.Environment env, Value key, Optional<FunctionValue> get, Optional<FunctionValue> set, Boolean enumerable, Boolean configurable) final boolean
deleteMember
(me.topchetoeu.j2s.common.Environment env, double key) final boolean
deleteMember
(me.topchetoeu.j2s.common.Environment env, int key) final boolean
deleteMember
(me.topchetoeu.j2s.common.Environment env, String key) final boolean
deleteMember
(me.topchetoeu.j2s.common.Environment env, KeyCache key) final boolean
deleteMember
(me.topchetoeu.j2s.common.Environment env, Value key) final boolean
deleteOwnMember
(me.topchetoeu.j2s.common.Environment env, double key) final boolean
deleteOwnMember
(me.topchetoeu.j2s.common.Environment env, int key) final boolean
deleteOwnMember
(me.topchetoeu.j2s.common.Environment env, String key) abstract boolean
deleteOwnMember
(me.topchetoeu.j2s.common.Environment env, KeyCache key) final boolean
deleteOwnMember
(me.topchetoeu.j2s.common.Environment env, Value key) static final NumberValue
static final String
errorToReadable
(me.topchetoeu.j2s.common.Environment env, RuntimeException err, String prefix) abstract void
freeze()
static FunctionValue
fromIterator
(me.topchetoeu.j2s.common.Environment ext, Iterable<? extends Value> iterable) final Value
getMember
(me.topchetoeu.j2s.common.Environment env, double key) final Value
getMember
(me.topchetoeu.j2s.common.Environment env, int key) final Value
final Value
final Value
final ObjectValue
getMemberDescriptor
(me.topchetoeu.j2s.common.Environment env, Value key) final Value
getMemberOrNull
(me.topchetoeu.j2s.common.Environment env, double key) final Value
getMemberOrNull
(me.topchetoeu.j2s.common.Environment env, int key) final Value
getMemberOrNull
(me.topchetoeu.j2s.common.Environment env, String key) final Value
getMemberOrNull
(me.topchetoeu.j2s.common.Environment env, KeyCache key) final Value
getMemberOrNull
(me.topchetoeu.j2s.common.Environment env, Value key) final Value
getMemberPath
(me.topchetoeu.j2s.common.Environment env, String... path) final Value
getMemberPath
(me.topchetoeu.j2s.common.Environment env, Value... path) getMembers
(me.topchetoeu.j2s.common.Environment env, boolean own, boolean onlyEnumerable) final Member
getOwnMember
(me.topchetoeu.j2s.common.Environment env, double key) final Member
getOwnMember
(me.topchetoeu.j2s.common.Environment env, int key) final Member
getOwnMember
(me.topchetoeu.j2s.common.Environment env, String key) abstract Member
getOwnMember
(me.topchetoeu.j2s.common.Environment env, KeyCache key) final Member
getOwnMember
(me.topchetoeu.j2s.common.Environment env, Value key) getOwnMembers
(me.topchetoeu.j2s.common.Environment env, boolean onlyEnumerable) abstract Set<SymbolValue>
getOwnSymbolMembers
(me.topchetoeu.j2s.common.Environment env, boolean onlyEnumerable) abstract ObjectValue
getPrototype
(me.topchetoeu.j2s.common.Environment env) abstract Value.State
getState()
final Set<SymbolValue>
getSymbolMembers
(me.topchetoeu.j2s.common.Environment env, boolean own, boolean onlyEnumerable) static final Value
global
(me.topchetoeu.j2s.common.Environment env) static final boolean
static final boolean
greaterOrEqual
(me.topchetoeu.j2s.common.Environment env, Value a, Value b) final boolean
hasMember
(me.topchetoeu.j2s.common.Environment env, double key, boolean own) final boolean
hasMember
(me.topchetoeu.j2s.common.Environment env, int key, boolean own) final boolean
final boolean
final boolean
intrinsics
(me.topchetoeu.j2s.common.Environment env) final boolean
isInstanceOf
(me.topchetoeu.j2s.common.Environment env, Value proto) final boolean
isNaN()
abstract boolean
static final boolean
static final boolean
lessOrEqual
(me.topchetoeu.j2s.common.Environment env, Value a, Value b) static final boolean
looseEqual
(me.topchetoeu.j2s.common.Environment env, Value a, Value b) static final NumberValue
static final NumberValue
static final NumberValue
static final NumberValue
abstract void
abstract void
seal()
final boolean
final boolean
final boolean
final boolean
final boolean
final boolean
setMemberIfExists
(me.topchetoeu.j2s.common.Environment env, double key, Value val) final boolean
setMemberIfExists
(me.topchetoeu.j2s.common.Environment env, int key, Value val) final boolean
setMemberIfExists
(me.topchetoeu.j2s.common.Environment env, String key, Value val) final boolean
setMemberIfExists
(me.topchetoeu.j2s.common.Environment env, KeyCache key, Value val) final boolean
setMemberIfExists
(me.topchetoeu.j2s.common.Environment env, Value key, Value val) abstract boolean
setPrototype
(me.topchetoeu.j2s.common.Environment env, ObjectValue val) static final NumberValue
static final NumberValue
shiftRight
(me.topchetoeu.j2s.common.Environment env, Value a, Value b) static final NumberValue
abstract boolean
toIterable
(me.topchetoeu.j2s.common.Environment env) abstract NumberValue
toNumber
(me.topchetoeu.j2s.common.Environment env) abstract Value
toPrimitive
(me.topchetoeu.j2s.common.Environment env) final String
toReadable
(me.topchetoeu.j2s.common.Environment ext) toReadableLines
(me.topchetoeu.j2s.common.Environment env, HashSet<ObjectValue> passed) abstract String
toString
(me.topchetoeu.j2s.common.Environment env) abstract StringValue
type()
static final NumberValue
unsignedShiftRight
(me.topchetoeu.j2s.common.Environment env, Value a, Value b) static final NumberValue
-
Field Details
-
BOOL_PROTO
-
NUMBER_PROTO
-
STRING_PROTO
-
SYMBOL_PROTO
-
OBJECT_PROTO
-
FUNCTION_PROTO
-
ARRAY_PROTO
-
INT8_ARR_PROTO
-
INT32_ARR_PROTO
-
UINT8_ARR_PROTO
-
ERROR_PROTO
-
SYNTAX_ERR_PROTO
-
TYPE_ERR_PROTO
-
RANGE_ERR_PROTO
-
GLOBAL
-
INTRINSICS
-
UNDEFINED
-
NULL
-
-
Constructor Details
-
Value
public Value()
-
-
Method Details
-
type
-
isPrimitive
public abstract boolean isPrimitive() -
isNaN
public final boolean isNaN() -
apply
-
construct
-
constructNoSelf
-
toPrimitive
-
toNumber
-
toString
-
toBoolean
public abstract boolean toBoolean() -
isInstanceOf
-
getOwnMember
-
getOwnMembers
-
getOwnSymbolMembers
public abstract Set<SymbolValue> getOwnSymbolMembers(me.topchetoeu.j2s.common.Environment env, boolean onlyEnumerable) -
defineOwnField
-
defineOwnProperty
public abstract boolean defineOwnProperty(me.topchetoeu.j2s.common.Environment env, KeyCache key, Optional<FunctionValue> get, Optional<FunctionValue> set, Boolean enumerable, Boolean configurable) -
deleteOwnMember
-
getPrototype
-
setPrototype
-
getState
-
preventExtensions
public abstract void preventExtensions() -
seal
public abstract void seal() -
freeze
public abstract void freeze() -
getOwnMember
-
getOwnMember
-
getOwnMember
-
getOwnMember
-
defineOwnProperty
public final boolean defineOwnProperty(me.topchetoeu.j2s.common.Environment env, Value key, Optional<FunctionValue> get, Optional<FunctionValue> set, Boolean enumerable, Boolean configurable) -
defineOwnProperty
public final boolean defineOwnProperty(me.topchetoeu.j2s.common.Environment env, String key, Optional<FunctionValue> get, Optional<FunctionValue> set, Boolean enumerable, Boolean configurable) -
defineOwnProperty
public final boolean defineOwnProperty(me.topchetoeu.j2s.common.Environment env, int key, Optional<FunctionValue> get, Optional<FunctionValue> set, Boolean enumerable, Boolean configurable) -
defineOwnProperty
public final boolean defineOwnProperty(me.topchetoeu.j2s.common.Environment env, double key, Optional<FunctionValue> get, Optional<FunctionValue> set, Boolean enumerable, Boolean configurable) -
defineOwnField
-
defineOwnField
-
defineOwnField
-
defineOwnField
-
defineOwnField
-
defineOwnField
-
defineOwnField
-
defineOwnField
-
defineOwnField
public final boolean defineOwnField(me.topchetoeu.j2s.common.Environment env, double key, Value val) -
deleteOwnMember
-
deleteOwnMember
-
deleteOwnMember
public final boolean deleteOwnMember(me.topchetoeu.j2s.common.Environment env, int key) -
deleteOwnMember
public final boolean deleteOwnMember(me.topchetoeu.j2s.common.Environment env, double key) -
getMemberOrNull
-
getMemberOrNull
-
getMemberOrNull
-
getMemberOrNull
-
getMemberOrNull
-
getMember
-
getMember
-
getMember
-
getMember
-
getMember
-
setMember
-
setMember
-
setMember
-
setMember
-
setMember
-
setMemberIfExists
-
setMemberIfExists
-
setMemberIfExists
-
setMemberIfExists
public final boolean setMemberIfExists(me.topchetoeu.j2s.common.Environment env, int key, Value val) -
setMemberIfExists
public final boolean setMemberIfExists(me.topchetoeu.j2s.common.Environment env, double key, Value val) -
hasMember
-
hasMember
-
hasMember
-
hasMember
public final boolean hasMember(me.topchetoeu.j2s.common.Environment env, int key, boolean own) -
hasMember
public final boolean hasMember(me.topchetoeu.j2s.common.Environment env, double key, boolean own) -
deleteMember
-
deleteMember
-
deleteMember
-
deleteMember
public final boolean deleteMember(me.topchetoeu.j2s.common.Environment env, int key) -
deleteMember
public final boolean deleteMember(me.topchetoeu.j2s.common.Environment env, double key) -
getMembers
-
getSymbolMembers
public final Set<SymbolValue> getSymbolMembers(me.topchetoeu.j2s.common.Environment env, boolean own, boolean onlyEnumerable) -
getMemberPath
-
getMemberPath
-
getMemberDescriptor
-
toIterable
-
callWith
-
callWithAsync
-
toReadableLines
public List<String> toReadableLines(me.topchetoeu.j2s.common.Environment env, HashSet<ObjectValue> passed) -
toReadable
-
global
-
intrinsics
-
fromIterator
public static FunctionValue fromIterator(me.topchetoeu.j2s.common.Environment ext, Iterable<? extends Value> iterable) -
lessOrEqual
-
greaterOrEqual
-
less
-
greater
-
add
-
subtract
public static final NumberValue subtract(me.topchetoeu.j2s.common.Environment env, Value a, Value b) -
multiply
public static final NumberValue multiply(me.topchetoeu.j2s.common.Environment env, Value a, Value b) -
divide
-
modulo
-
negative
-
and
-
or
-
xor
-
bitwiseNot
-
shiftLeft
public static final NumberValue shiftLeft(me.topchetoeu.j2s.common.Environment env, Value a, Value b) -
shiftRight
public static final NumberValue shiftRight(me.topchetoeu.j2s.common.Environment env, Value a, Value b) -
unsignedShiftRight
public static final NumberValue unsignedShiftRight(me.topchetoeu.j2s.common.Environment env, Value a, Value b) -
looseEqual
-
errorToReadable
public static final String errorToReadable(me.topchetoeu.j2s.common.Environment env, RuntimeException err, String prefix)
-