com.gargoylesoftware.htmlunit.javascript.host
Class FormField

java.lang.Object
  extended by org.mozilla.javascript.ScriptableObject
      extended by com.gargoylesoftware.htmlunit.javascript.SimpleScriptable
          extended by com.gargoylesoftware.htmlunit.javascript.host.NodeImpl
              extended by com.gargoylesoftware.htmlunit.javascript.host.HTMLElement
                  extended by com.gargoylesoftware.htmlunit.javascript.host.FocusableHostElement
                      extended by com.gargoylesoftware.htmlunit.javascript.host.FormField
All Implemented Interfaces:
ScriptableWithFallbackGetter, java.io.Serializable, org.mozilla.javascript.ConstProperties, org.mozilla.javascript.debug.DebuggableObject, org.mozilla.javascript.Scriptable
Direct Known Subclasses:
Button, HTMLInputElement, HTMLSelectElement, HTMLTextAreaElement

public class FormField
extends FocusableHostElement

Base class for all javascript object corresponding to form fields.

Version:
$Revision: 1.3 $
Author:
Mike Bowler, Christian Sell, Marc Guillemot, Chris Erskine, Ahmed Ashour
See Also:
Serialized Form

Field Summary
 
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
FormField()
  
 
Method Summary
 void jsxFunction_click()
 Click this element.
 void jsxFunction_select()
 Select this element.
 boolean jsxGet_disabled()
 Return true if this element is disabled.
 HTMLFormElement jsxGet_form()
 Return the value of the javascript attribute "form".
 java.lang.String jsxGet_name()
 Return the value of the javascript attribute "name".
 org.mozilla.javascript.Function jsxGet_onchange()
 Get the onchange event handler for this element.
 java.lang.String jsxGet_tabindex()
 Return the value of the tabindex attribute.
 java.lang.String jsxGet_type()
 Return the value of the javascript attribute "type".
 java.lang.String jsxGet_value()
 Return the value of the javascript attribute "value".
 void jsxSet_disabled(boolean disabled)
 Set whether or not to disable this element
 void jsxSet_name(java.lang.String newName)
 Set the value of the javascript attribute "name".
 void jsxSet_onchange(java.lang.Object onchange)
 Set the onchange event handler for this element.
 void jsxSet_value(java.lang.String newValue)
 Set the value of the javascript attribute "value".
 void setDomNode(DomNode domNode)
 Sets the associated dom node and sets the enclosing form as parent scope of the current element
 
Methods inherited from class com.gargoylesoftware.htmlunit.javascript.host.FocusableHostElement
jsxFunction_blur, jsxFunction_focus
 
Methods inherited from class com.gargoylesoftware.htmlunit.javascript.host.HTMLElement
addComponentRequest, clearComponentRequest, compareVersions, doComponentRequest, getAvailHeight, getAvailWidth, getBufferDepth, getColorDepth, getComponentVersion, getConnectionType, getCookieEnabled, getCpuClass, getHeight, getJavaEnabled, getPlatform, getSystemLanguage, getUserLanguage, getWidth, getWithFallback, isComponentInstalled, isHomePage, jsxFunction_addBehavior, jsxFunction_getAttribute, jsxFunction_getAttributeNode, jsxFunction_getBoundingClientRect, jsxFunction_getClientRects, jsxFunction_getElementsByTagName, jsxFunction_insertAdjacentElement, jsxFunction_insertAdjacentHTML, jsxFunction_removeAttribute, jsxFunction_removeBehavior, jsxFunction_scrollIntoView, jsxFunction_setAttribute, jsxFunction_setAttributeNode, jsxGet_all, jsxGet_children, jsxGet_className, jsxGet_currentStyle, jsxGet_id, jsxGet_innerHTML, jsxGet_innerText, jsxGet_localName, jsxGet_namespaceURI, jsxGet_offsetHeight, jsxGet_offsetLeft, jsxGet_offsetParent, jsxGet_offsetTop, jsxGet_offsetWidth, jsxGet_onblur, jsxGet_onclick, jsxGet_oncontextmenu, jsxGet_ondblclick, jsxGet_onfocus, jsxGet_onkeydown, jsxGet_onkeypress, jsxGet_onkeyup, jsxGet_onmousedown, jsxGet_onmousemove, jsxGet_onmouseout, jsxGet_onmouseover, jsxGet_onmouseup, jsxGet_onresize, jsxGet_outerHTML, jsxGet_ownerDocument, jsxGet_parentElement, jsxGet_prefix, jsxGet_runtimeStyle, jsxGet_scrollHeight, jsxGet_scrollLeft, jsxGet_scrollTop, jsxGet_scrollWidth, jsxGet_style, jsxGet_tagName, jsxGet_title, jsxSet_className, jsxSet_id, jsxSet_innerHTML, jsxSet_innerText, jsxSet_onblur, jsxSet_onclick, jsxSet_oncontextmenu, jsxSet_ondblclick, jsxSet_onfocus, jsxSet_onkeydown, jsxSet_onkeypress, jsxSet_onkeyup, jsxSet_onmousedown, jsxSet_onmousemove, jsxSet_onmouseout, jsxSet_onmouseover, jsxSet_onmouseup, jsxSet_onresize, jsxSet_outerHTML, jsxSet_scrollLeft, jsxSet_scrollTop, jsxSet_title, navigateHomePage, setHomePage, startDownload, toString
 
Methods inherited from class com.gargoylesoftware.htmlunit.javascript.host.NodeImpl
executeEvent, fireEvent, getEventHandler, jsxFunction_addEventListener, jsxFunction_appendChild, jsxFunction_attachEvent, jsxFunction_cloneNode, jsxFunction_detachEvent, jsxFunction_hasChildNodes, jsxFunction_insertBefore, jsxFunction_isSameNode, jsxFunction_removeChild, jsxFunction_removeEventListener, jsxFunction_replaceChild, jsxGet_childNodes, jsxGet_firstChild, jsxGet_lastChild, jsxGet_nextSibling, jsxGet_nodeName, jsxGet_nodeType, jsxGet_nodeValue, jsxGet_parentNode, jsxGet_previousSibling, jsxSet_nodeValue, setEventHandler
 
Methods inherited from class com.gargoylesoftware.htmlunit.javascript.SimpleScriptable
get, getBooleanArg, getClassName, getDefaultValue, getDomNodeOrDie, getDomNodeOrNull, getHtmlElementOrDie, getHtmlElementOrNull, getIntArg, getObjectArg, getStringArg, makeScriptableFor, setHtmlElement
 
Methods inherited from class org.mozilla.javascript.ScriptableObject
associateValue, avoidObjectDetection, callMethod, callMethod, defineClass, defineClass, defineClass, defineConst, defineConstProperty, defineFunctionProperties, defineProperty, defineProperty, defineProperty, defineProperty, delete, delete, deleteProperty, deleteProperty, get, getAllIds, getAssociatedValue, getAttributes, getAttributes, getAttributes, getAttributes, getClassPrototype, getDefaultValue, getFunctionPrototype, getGetterOrSetter, getIds, getObjectPrototype, getParentScope, getProperty, getProperty, getPropertyIds, getPrototype, getTopLevelScope, getTopScopeValue, has, has, hasInstance, hasProperty, hasProperty, isConst, isSealed, put, put, putConst, putConstProperty, putProperty, putProperty, redefineProperty, sealObject, setAttributes, setAttributes, setAttributes, setAttributes, setGetterOrSetter, setParentScope, setPrototype
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.mozilla.javascript.Scriptable
delete, delete, get, get, getClassName, getDefaultValue, getIds, getParentScope, getPrototype, has, has, hasInstance, put, put, setParentScope, setPrototype
 

Constructor Detail

FormField

public FormField()
Method Detail

jsxFunction_click

public void jsxFunction_click()
                       throws java.io.IOException
Click this element. This simulates the action of the user clicking with the mouse.

Throws:
java.io.IOException - if this click triggers a page load that encouters problems

jsxFunction_select

public void jsxFunction_select()
Select this element.


jsxGet_disabled

public boolean jsxGet_disabled()
Return true if this element is disabled.

Overrides:
jsxGet_disabled in class HTMLElement
Returns:
True if this element is disabled.

jsxGet_form

public HTMLFormElement jsxGet_form()
Return the value of the javascript attribute "form".

Returns:
The value of this attribute.

jsxGet_name

public java.lang.String jsxGet_name()
Return the value of the javascript attribute "name".

Returns:
The value of this attribute.

jsxGet_onchange

public org.mozilla.javascript.Function jsxGet_onchange()
Get the onchange event handler for this element.

Returns:
org.mozilla.javascript.Function

jsxGet_tabindex

public java.lang.String jsxGet_tabindex()
Return the value of the tabindex attribute.

Returns:
the value of the tabindex attribute.

jsxGet_type

public java.lang.String jsxGet_type()
Return the value of the javascript attribute "type".

Returns:
The value of this attribute.

jsxGet_value

public java.lang.String jsxGet_value()
Return the value of the javascript attribute "value".

Returns:
The value of this attribute.

jsxSet_disabled

public void jsxSet_disabled(boolean disabled)
Set whether or not to disable this element

Overrides:
jsxSet_disabled in class HTMLElement
Parameters:
disabled - True if this is to be disabled.

jsxSet_name

public void jsxSet_name(java.lang.String newName)
Set the value of the javascript attribute "name".

Parameters:
newName - The new name.

jsxSet_onchange

public void jsxSet_onchange(java.lang.Object onchange)
Set the onchange event handler for this element.

Parameters:
onchange - the new handler

jsxSet_value

public void jsxSet_value(java.lang.String newValue)
Set the value of the javascript attribute "value".

Parameters:
newValue - The new value.

setDomNode

public void setDomNode(DomNode domNode)
Sets the associated dom node and sets the enclosing form as parent scope of the current element

Overrides:
setDomNode in class HTMLElement
Parameters:
domNode - The DOM node
See Also:
SimpleScriptable.setDomNode(DomNode)


Copyright © 2003-2016 AppPerfect Corporation. All Rights Reserved.