Class LiveObject
- java.lang.Object
-
- org.mozilla.javascript.ScriptableObject
-
- com.adobe.xfa.scripthandler.rhino.LiveObject
-
- All Implemented Interfaces:
java.io.Serializable
,ConstProperties
,DebuggableObject
,Scriptable
public class LiveObject extends ScriptableObject
A class to expose XFA objects to JavaScript scripting. Each scriptable XFA objects is peered to instances of this class.- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
CLASSNAME
-
Fields inherited from class org.mozilla.javascript.ScriptableObject
CONST, DONTENUM, EMPTY, PERMANENT, READONLY, UNINITIALIZED_CONST
-
Fields inherited from interface org.mozilla.javascript.Scriptable
NOT_FOUND
-
-
Constructor Summary
Constructors Constructor Description LiveObject(RhinoScriptHandler handler, Obj xfaObject)
Instantiates a LiveObject object.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Object
get(java.lang.String name, Scriptable start)
Gets the value of the named property of this object.java.lang.String
getClassName()
Gets the name of the class.static java.lang.Object
invoke(Context cx, Scriptable obj, java.lang.Object[] args, Function func)
void
jsConstructor(java.lang.Object handler, java.lang.Object xfaObject)
Defines the JavaScript constructor to Rhino.void
put(java.lang.String name, Scriptable start, java.lang.Object value)
Puts the value of the named property of the start object.-
Methods inherited from class org.mozilla.javascript.ScriptableObject
associateValue, avoidObjectDetection, callMethod, callMethod, defineClass, defineClass, defineClass, defineConst, defineConstProperty, defineFunctionProperties, defineOwnProperties, defineOwnProperty, defineProperty, defineProperty, defineProperty, defineProperty, delete, delete, deleteProperty, deleteProperty, get, get, getAllIds, getArrayPrototype, getAssociatedValue, getAttributes, getAttributes, getAttributes, getAttributes, getClassPrototype, getDefaultValue, getDefaultValue, getExternalArrayData, getExternalArrayLength, getFunctionPrototype, getGetterOrSetter, getIds, getObjectPrototype, getParentScope, getProperty, getProperty, getPropertyIds, getPrototype, getTopLevelScope, getTopScopeValue, getTypedProperty, getTypedProperty, getTypeOf, has, has, hasInstance, hasProperty, hasProperty, isConst, isEmpty, isExtensible, isSealed, preventExtensions, put, putConst, putConstProperty, putProperty, putProperty, redefineProperty, sealObject, setAttributes, setAttributes, setAttributes, setAttributes, setExternalArrayData, setGetterOrSetter, setParentScope, setPrototype, size
-
-
-
-
Field Detail
-
CLASSNAME
public static final java.lang.String CLASSNAME
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
LiveObject
public LiveObject(RhinoScriptHandler handler, Obj xfaObject)
Instantiates a LiveObject object. The lone constructor used by this package to create instances of this class.- Parameters:
handler
- a Rhino script handler.xfaObject
- the XFA object that is peered to this object.
-
-
Method Detail
-
jsConstructor
public void jsConstructor(java.lang.Object handler, java.lang.Object xfaObject)
Defines the JavaScript constructor to Rhino.This method is required by the Scriptable interface and must mirror the signature of the class constructor.
- Parameters:
handler
- a Rhino script handler.xfaObject
- the XFA object that is peered to this object.
-
getClassName
public java.lang.String getClassName()
Gets the name of the class.- Specified by:
getClassName
in interfaceScriptable
- Specified by:
getClassName
in classScriptableObject
-
get
public java.lang.Object get(java.lang.String name, Scriptable start)
Gets the value of the named property of this object.- Specified by:
get
in interfaceScriptable
- Overrides:
get
in classScriptableObject
- Parameters:
name
- the name of the property.start
- the object in which the lookup began.- Returns:
- the value of the property, or NOT_FOUND if the property is not a property of this object's peered XFA object.
- Throws:
EvaluatorException
- whenever an ExFull was thrown while getting the XFA property.- See Also:
Context.getUndefinedValue()
-
put
public void put(java.lang.String name, Scriptable start, java.lang.Object value)
Puts the value of the named property of the start object.This method may (or not) set the property in the start object.
- Specified by:
put
in interfaceScriptable
- Overrides:
put
in classScriptableObject
- Parameters:
name
- the name of the property.start
- the object whose property is being set.value
- the value to set the property to.- See Also:
Scriptable.has(String, Scriptable)
,Scriptable.get(String, Scriptable)
,ScriptableObject.putProperty(Scriptable, String, Object)
,Context.toObject(Object, Scriptable)
-
invoke
public static java.lang.Object invoke(Context cx, Scriptable obj, java.lang.Object[] args, Function func)
-
-