public class LeoNativeClass extends LeoObject
LeoObject.LeoType
Constructor and Description |
---|
LeoNativeClass() |
LeoNativeClass(Class<?> nativeClass,
Object instance) |
LeoNativeClass(Object instance) |
Modifier and Type | Method and Description |
---|---|
LeoObject |
$add(LeoObject other) |
boolean |
$eq(LeoObject other)
Determines if it equals another object.
|
boolean |
$gt(LeoObject other)
If it's greater than to another object
|
LeoObject |
$index(LeoObject other) |
boolean |
$lt(LeoObject other)
If it's less than to another object
|
boolean |
$req(LeoObject other)
Tests if the references are the same.
|
void |
$sindex(LeoObject key,
LeoObject other) |
LeoObject |
clone() |
boolean |
equals(Object obj) |
Field |
getField(String fieldName) |
Object |
getInstance() |
LeoObject |
getMember(LeoObject member)
Attempt to retrieve a native member of the supplied Java class.
|
List<Method> |
getMethods(String methodName) |
Class<?> |
getNativeClass() |
LeoObject |
getObject(LeoObject key)
Retrieves a property from this object.
|
Object |
getValue() |
Object |
getValue(Class<?> narrowType)
Attempts to narrow the
LeoObject to a more specific Java Type |
int |
hashCode() |
boolean |
hasObject(LeoObject key)
Determines if the supplied key has an associated value
|
boolean |
is(String className) |
boolean |
isAssignable(Class<?> javaType)
Determines if the supplied Java type can be assigned to this
LeoObject . |
boolean |
isClass() |
boolean |
isNativeClass() |
boolean |
isOfType(String rawType)
Determines if this type is of the supplied type.
|
void |
setInstance(Object instance) |
void |
setMember(LeoObject member,
LeoObject value)
Attempts to set the Java objects field.
|
void |
setObject(LeoObject key,
LeoObject value)
Sets a property on this object.
|
String |
toString() |
void |
write(DataOutput out)
Writes this object out
|
LeoObject |
xgetObject(LeoObject key)
Similar to
LeoObject.getObject(LeoObject) in every way, with the exception that
this will throw a LeolaRuntimeException is the attribute is not found. |
$add, $add, $add, $band, $band, $band, $band, $bnot, $bor, $bor, $bor, $bor, $bsl, $bsl, $bsl, $bsl, $bsr, $bsr, $bsr, $bsr, $div, $div, $div, $div, $eq, $eq, $eq, $eq, $gt, $gt, $gt, $gte, $gte, $gte, $gte, $index, $index, $index, $lt, $lt, $lt, $lte, $lte, $lte, $lte, $mod, $mod, $mod, $mod, $mul, $mul, $mul, $mul, $neg, $neq, $neq, $neq, $neq, $sub, $sub, $sub, $sub, $xor, $xor, $xor, $xor, as, as, asByte, asChar, asDouble, asFloat, asInt, asLong, asShort, call, call, call, call, call, call, call, compareTo, getLocals, getNativeMember, getNativeMethod, getNativeMethod, getNumberOfArgs, getObject, getOuters, getScope, getType, hasNativeMethod, hasNativeMethod, hasObject, hasVarargs, isArray, isBoolean, isError, isFunction, isGenerator, isMap, isNamespace, isNativeFunction, isNull, isNumber, isOfType, isOfType, isOfType, isOuter, isScopedObject, isString, isTrue, isTrue, read, removeInterfaceMethods, rethrow, setObject, throwAttributeAccessError, throwAttributeError, throwAttributeError, throwClassNotFoundError, throwDivideByZeroError, throwIfError, throwMethodError, throwNativeMethodError, throwNotImplementedError, toJavaObject, toLeoString, valueOf, xcall, xcall, xcall, xcall, xcall, xcall, xcall, xgetObject
public LeoNativeClass()
public LeoNativeClass(Object instance)
instance
- public boolean isOfType(String rawType)
LeoObject
public boolean is(String className)
className
- public boolean isNativeClass()
isNativeClass
in class LeoObject
public void setObject(LeoObject key, LeoObject value)
LeoObject
public LeoObject xgetObject(LeoObject key)
LeoObject
LeoObject.getObject(LeoObject)
in every way, with the exception that
this will throw a LeolaRuntimeException
is the attribute is not found.xgetObject
in class LeoObject
public LeoObject getObject(LeoObject key)
LeoObject
LeoObject
supports associations, this
will attempt to find the object with the associated key. If the key is not found, this will return LeoObject.NULL
.getObject
in class LeoObject
LeoObject.NULL
LeoObject.xgetObject(LeoObject)
public boolean hasObject(LeoObject key)
LeoObject
public LeoObject getMember(LeoObject member)
member
- public void setMember(LeoObject member, LeoObject value)
member
- value
- public Class<?> getNativeClass()
public Field getField(String fieldName)
fieldName
- public List<Method> getMethods(String methodName)
methodName
- public Object getInstance()
public void setInstance(Object instance)
instance
- the instance to setpublic boolean $req(LeoObject other)
LeoObject
public boolean $eq(LeoObject other)
LeoObject
public boolean $gt(LeoObject other)
LeoObject
public boolean $lt(LeoObject other)
LeoObject
public Object getValue()
public Object getValue(Class<?> narrowType)
LeoObject
LeoObject
to a more specific Java Typepublic boolean isAssignable(Class<?> javaType)
LeoObject
LeoObject
.isAssignable
in class LeoObject
LeoObject
public LeoObject clone()
public void write(DataOutput out) throws IOException
LeoObject
write
in class LeoObject
IOException
Copyright © 2010–2015. All rights reserved.