| com.gargoylesoftware.htmlunit.javascript.ScriptableWrapper
ScriptableWrapper | public class ScriptableWrapper extends ScriptableObject (Code) | | Simple wrapper to make "normal" object scriptable according to specific configuration
and allowing use of index properties.
TODO: Configuration of the
properties and functions should occur from the xml configuration according to
the browser to simulate.
version: $Revision: 2132 $ author: Marc Guillemot |
Constructor Summary | |
public | ScriptableWrapper(Scriptable scope, Object javaObject, Class staticType) Constructs a wrapper for the java object. |
ScriptableWrapper | public ScriptableWrapper(Scriptable scope, Object javaObject, Class staticType)(Code) | | Constructs a wrapper for the java object.
Parameters: scope - the scope of the executing script Parameters: javaObject - the javaObject to wrap Parameters: staticType - the static type of the object |
get | public Object get(String name, Scriptable start)(Code) | | See Also: org.mozilla.javascript.ScriptableObject.get(java.lang.Stringorg.mozilla.javascript.Scriptable) |
get | public Object get(int index, Scriptable start)(Code) | | See Also: org.mozilla.javascript.ScriptableObject.get(intorg.mozilla.javascript.Scriptable) |
getClassName | public String getClassName()(Code) | | See Also: org.mozilla.javascript.ScriptableObject.getClassName |
getDefaultValue | public Object getDefaultValue(Class hint)(Code) | | See Also: org.mozilla.javascript.ScriptableObject.getDefaultValue(java.lang.Class) |
getWrappedObject | public Object getWrappedObject()(Code) | | Gets the java object made availabe to javascript through this wrapper
the wrapped object |
has | public boolean has(String name, Scriptable start)(Code) | | See Also: org.mozilla.javascript.ScriptableObject.has(java.lang.Stringorg.mozilla.javascript.Scriptable) |
invoke | protected Object invoke(Method method)(Code) | | Invokes the method on the wrapped object
Parameters: method - the method to invoke the invocation result |
invoke | protected Object invoke(Method method, Object[] args)(Code) | | Invokes the method on the wrapped object
Parameters: method - the method to invoke Parameters: args - the argument to pass to the method the invocation result |
jsToString | public String jsToString()(Code) | | To use as "toString" function in javascript
the string representation |
|
|