JSObject : Object

Java representation of a JavaScript object.

Browser/User Agent Support

IEMozillaNetscapeOperaSafari
4.0+1.0+3.0+7.0+1.0+

Constructors

ConstructorIEMozillaNetscapeOperaSafari
Creates a new instance of a JSObject.
4.0+1.0+3.0+7.0+1.0+
 

Methods

MethodIEMozillaNetscapeOperaSafari
Invokes the specified method of the JavaScript object.
4.0+1.0+3.0+7.0+1.0+
 
Evaluates a piece of JavaScript code.
4.0+1.0+3.0+7.0+1.0+
 
Gets the value of a JavaScript property.
4.0+1.0+3.0+7.0+1.0+
 
Gets the value of an element in a JavaScript array.
4.0+1.0+3.0+7.0+1.0+
 
Gets a JSObject for a browser window.
4.0+1.0+3.0+7.0+1.0+
 
Deletes a property from a JavaScript object.
4.0+1.0+3.0+7.0+1.0+
 
Sets the value of a property for a JavaScript object.
4.0+1.0+3.0+7.0+1.0+
 
Sets the value of an array element for a JavaScript object.
4.0+1.0+3.0+7.0+1.0+
 
Calls toString on a JavaScript object.
4.0+1.0+3.0+7.0+1.0+
 

Constructor Detail

JSObject JSObject()

Creates a new instance of a JSObject.

Visibility
internal

Method Detail

call(String methodName, Array args) : Object

Invokes the specified method of the JavaScript object.

StringmethodNameMethod to invoke.
ArrayargsArguments (if any) to be taken by the method.

eval(String s) : Object

Evaluates a piece of JavaScript code.

StringsCode to be evaluated.

getMember(String name) : String

Gets the value of a JavaScript property.

StringnameName of the property.

getSlot(int index) : Object

Gets the value of an element in a JavaScript array.

intindexIndex of the element in the array.

getWindow(java.applet.Applet applet) : Object

Gets a JSObject for a browser window.

java.applet.AppletappletApplet to obtain a JSObject for.

removeMember(String name) : Object

Deletes a property from a JavaScript object.

StringnameName of the property.

setMember(String name, Object value) : Object

Sets the value of a property for a JavaScript object.

StringnameName of the property.
ObjectvalueValue that the property should be set to.

setSlot(int index, Object value) : Object

Sets the value of an array element for a JavaScript object.

intindexIndex of the element in the array to be set.
ObjectvalueValue of the element to be set.

toString() : String

Calls toString on a JavaScript object.