    All Packages  Class Hierarchy  This Package  Previous  Next  Index

# Class w3c.jigsaw.forms.CheckBoxField

    java.lang.Object
       |
       +----w3c.jigsaw.forms.FormField
               |
               +----w3c.jigsaw.forms.CheckBoxField

public class CheckBoxField
extends FormField

##

CheckBoxField(String, String, String, boolean)
  Create a new check box field.

##

dump(HtmlGenerator)
  Dump this field as a form element.
getValue()
  Get this field value.
initialize(String, String, String, Object)
setValue(boolean)
  Set this field value.
setValue(String)
  Set this boolean field value to the given string value.

##

CheckBoxField

     public CheckBoxField(String name,
                          String title,
                          String url,
                          boolean val)

  Create a new check box field.

  Parameters:
    name - The name of this field.
    title - It's title.
    value - Its default value.

##

getValue

     public Object getValue()

  Get this field value.

  Returns:
    An instance of Boolean.
  Overrides:
    getValue in class FormField

setValue

     public void setValue(boolean bval)

  Set this field value. This method doesn't notify the form handler of the change./

  Parameters:
    bval - The new field's value.

setValue

     public boolean setValue(String nval) throws FormFieldException

  Set this boolean field value to the given string value. If the field value is changed, than the handler gets notified, otherwise, a FormFieldException is thrown.

  Parameters:
    nval - The new string value for this field.
  Returns:
    A boolean true if the field was changed.
  Throws: FormFieldException
    If the given value doesn't match the expected type for the field.
  Overrides:
    setValue in class FormField

dump

     public void dump(HtmlGenerator into)

  Dump this field as a form element.

  Parameters:
    into - The HtmlGenerator to dump the field into.
  Overrides:
    dump in class FormField

initialize

     public void initialize(String name,
                            String title,
                            String url,
                            Object val) throws FormFieldException

  Overrides:
    initialize in class FormField

    All Packages  Class Hierarchy  This Package  Previous  Next  Index