cx.ath.matthew.cgi

Class HTMLForm


public class HTMLForm
extends Object

Class to manage drawing HTML forms

Constructor Summary

HTMLForm(String target)
HTMLForm(String target, String submitlabel)
HTMLForm(String target, String submitlabel, String tableclass)

Method Summary

void
addField(Field field)
Add a field to be displayed in the form.
void
display(CGI cgi)
Shows the form.
void
setGET(boolean enable)
Set GET method rather than POST

Constructor Details

HTMLForm

public HTMLForm(String target)
Parameters:
target - The module to submit to

HTMLForm

public HTMLForm(String target,
                String submitlabel)
Parameters:
target - The module to submit to
submitlabel - The string to display on the submit button

HTMLForm

public HTMLForm(String target,
                String submitlabel,
                String tableclass)
Parameters:
target - The module to submit to
submitlabel - The string to display on the submit button
tableclass - The class= parameter for the generated table

Method Details

addField

public void addField(Field field)
Add a field to be displayed in the form.
Parameters:
field - A Field subclass.

display

public void display(CGI cgi)
Shows the form.
Parameters:
cgi - The CGI instance that is handling output

setGET

public void setGET(boolean enable)
Set GET method rather than POST
Parameters:
enable - Enable/Disable GET