Primitive
- the type parameterpublic abstract class V8ValuePrimitive<Primitive> extends V8Value
Modifier and Type | Field and Description |
---|---|
protected Primitive |
value
The Value.
|
OBJECT_CONVERTER, v8Runtime
Constructor and Description |
---|
V8ValuePrimitive(V8Runtime v8Runtime)
Instantiates a new V8 value primitive.
|
V8ValuePrimitive(V8Runtime v8Runtime,
Primitive value)
Instantiates a new V8 value primitive.
|
Modifier and Type | Method and Description |
---|---|
void |
close() |
boolean |
equals(V8Value v8Value)
Equals.
|
Primitive |
getValue()
Gets the primitive value.
|
boolean |
isEmpty()
Is empty.
|
boolean |
isPresent()
Is present.
|
boolean |
sameValue(V8Value v8Value)
Same value.
|
boolean |
strictEquals(V8Value v8Value)
Strict equals.
|
java.lang.String |
toString() |
checkV8Runtime, getV8Runtime, isClosed
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
asBoolean, asDouble, asInt, asLong, asString, isNull, isNullOrUndefined, isUndefined
toClone, toClone
protected Primitive value
public V8ValuePrimitive(V8Runtime v8Runtime) throws JavetException
v8Runtime
- the V8 runtimeJavetException
- the javet exceptionpublic V8ValuePrimitive(V8Runtime v8Runtime, Primitive value) throws JavetException
v8Runtime
- the V8 runtimevalue
- the valueJavetException
- the javet exceptionpublic void close() throws JavetException
close
in interface IJavetClosable
close
in interface java.lang.AutoCloseable
close
in class V8Value
JavetException
public boolean equals(V8Value v8Value)
IV8Value
The behavior is different from JS behavior but is the same as Java behavior.
public Primitive getValue()
public boolean isEmpty()
public boolean isPresent()
public boolean sameValue(V8Value v8Value)
IV8Value
The behavior is different from JS behavior but is the same as Java behavior.
public boolean strictEquals(V8Value v8Value)
IV8Value
The behavior is different from JS behavior but is the same as Java behavior.
strictEquals
in interface IV8Value
strictEquals
in class V8Value
v8Value
- the V8 valuepublic java.lang.String toString()
toString
in class java.lang.Object