fi.hut.tml.xsmiles.mlfc.xforms.adaptive
Class InputBoolean

java.lang.Object
  extended byfi.hut.tml.xsmiles.mlfc.xforms.adaptive.AbstractControl
      extended byfi.hut.tml.xsmiles.mlfc.xforms.adaptive.InputBoolean
All Implemented Interfaces:
Control, java.util.EventListener, FormControl, java.awt.event.ItemListener, TypedElement

public class InputBoolean
extends AbstractControl
implements java.awt.event.ItemListener

this is the element control implementation when the datatype is derived from xsd:boolean. It is represented as a single checkbox


Field Summary
protected  XSelectBoolean fSelect
           
 
Fields inherited from class fi.hut.tml.xsmiles.mlfc.xforms.adaptive.AbstractControl
fActionListener, fChangeListener, fContext, insideEvent, ownerElem
 
Constructor Summary
InputBoolean(XFormsContext context, org.w3c.dom.Element elem)
           
 
Method Summary
protected  void createControl()
           
 void destroy()
          close up, free all memory (yet, do not do visible changes, such as setVisible since this will slow things up
 XComponent getComponent()
          returns the abstract component for this control.
 Data getValue()
          get the components current value
 void itemStateChanged(java.awt.event.ItemEvent e)
          This handles the changes from the widget XSelectBoolean
protected  void registerListener()
          internal method for setting the listener for the component
 void updateDisplay()
          this function is used to notify the control to update its display according to the content of Data
 
Methods inherited from class fi.hut.tml.xsmiles.mlfc.xforms.adaptive.AbstractControl
activate, activate, addActionListener, addChangeListener, getData, getDataType, isInputControl, isWritable, rewiringAboutToHappen, setData
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

fSelect

protected XSelectBoolean fSelect
Constructor Detail

InputBoolean

public InputBoolean(XFormsContext context,
                    org.w3c.dom.Element elem)
Method Detail

createControl

protected void createControl()

getComponent

public XComponent getComponent()
returns the abstract component for this control. The abstract component can be used e.g. to style the component but all listeners should be added to the AdaptiveControl and not directly to the XComponent

Specified by:
getComponent in interface Control

registerListener

protected void registerListener()
internal method for setting the listener for the component


destroy

public void destroy()
Description copied from class: AbstractControl
close up, free all memory (yet, do not do visible changes, such as setVisible since this will slow things up

Specified by:
destroy in interface Control
Overrides:
destroy in class AbstractControl

updateDisplay

public void updateDisplay()
this function is used to notify the control to update its display according to the content of Data

Specified by:
updateDisplay in interface Control

itemStateChanged

public void itemStateChanged(java.awt.event.ItemEvent e)
This handles the changes from the widget XSelectBoolean

Specified by:
itemStateChanged in interface java.awt.event.ItemListener

getValue

public Data getValue()
get the components current value

Specified by:
getValue in interface Control


X-Smiles 1.2