www.element4solution.com

e4s.html
Class FORM

java.lang.Object
  extended by e4s.util.E4Object
      extended by e4s.html.E4HtmlObject
          extended by e4s.html.E4HtmlElementGeneral
              extended by e4s.html.E4HtmlElement
                  extended by e4s.html.E4HtmlContentElement
                      extended by e4s.html.E4HtmlContentElementPersistant
                          extended by e4s.html.FORM
All Implemented Interfaces:
E4HtmlElement_Intf

public class FORM
extends E4HtmlContentElementPersistant
implements E4HtmlElement_Intf

Input forms (<FORM>-tag). An input form is a collection of one or more input fields. In the E4S environment, this also can be combination of fields, tabbed fields, grouped fields, lists, .. Typical construction for a FORM might be html.BODY().FORM(). {@tutorial

Example_FileUpload.java

Since:
JDK 1.4
See Also:
e4s.html.input.extended, FORM_Button, FORM_Submit, FORM_Reset, E4EventHandlerFORM

Field Summary
static STYLE_Name DEFAULTSTYLE
           
static java.lang.String ENCRYPTION_MULTIPART_FORM_DATA
          A encryption type for multidata requests (used to upload files)
static java.lang.String JS_FORM_HANDLING
           
static java.lang.String JS_SUBMIT_CLIENT
           
 
Fields inherited from class e4s.html.E4HtmlContentElement
BOOL_STR_FALSE, BOOL_STR_TRUE
 
Fields inherited from class e4s.html.E4HtmlElementGeneral
m_elements, m_needed_scripts
 
Fields inherited from class e4s.html.E4HtmlObject
m_parent_e4sID
 
Fields inherited from class e4s.util.E4Object
CRLF, E4S_CORE_SYSTEM_LANGUAGE, NBSP, NULLSTR, URL_ENCODING_CHARSET
 
Constructor Summary
FORM()
           
FORM(E4ID parent_id)
           
FORM(E4ID parent_id, E4Method mref)
           
FORM(E4ID parent_id, java.lang.String name)
           
FORM(E4Method mref)
           
FORM(java.lang.String name)
           
 
Method Summary
static java.lang.String _getSVNVersionString()
          Get version info string from subversion.
 void addElement(E4Fieldset fieldset)
           
 void addElement(E4HtmlElement_Intf element)
          Adds an element to the internal Vector.
 E4BasicTextInput BasicTextInput(java.lang.String name)
          Deprecated.  
 BUTTON BUTTON_Reset()
           
 BUTTON BUTTON_Reset(E4Label_Intf label)
           
 BUTTON BUTTON_Reset(java.lang.String label)
           
 BUTTON BUTTON_Submit()
           
 BUTTON BUTTON_Submit(E4Label_Intf label)
           
 BUTTON BUTTON_Submit(java.lang.String label)
           
 BUTTON BUTTON(char type)
           
 BUTTON BUTTON(E4Label_Intf label, char type)
           
 BUTTON BUTTON(java.lang.String label, char type)
           
 CHECKBOX CHECKBOX(E4InputFieldName_Intf name, E4Label_Intf label)
           
 CHECKBOX CHECKBOX(E4InputFieldName_Intf name, java.lang.String label)
           
static E4JavaScript createFormScript()
           
 DATEFIELD DATEFIELD(E4InputFieldName_Intf name, E4Label_Intf label)
           
 DATEFIELD DATEFIELD(E4InputFieldName_Intf name, java.lang.String label)
           
 DATEFIELD DATEFIELD(E4InputFieldName_Intf name, java.lang.String label, boolean default_pickup)
           
 E4ID E4ID()
          Get the E4ID of the object.
 E4InputMultiState E4InputMultiState(E4InputFieldName_Intf name, E4Label_Intf label, E4InputMultiStateOptions selection)
           
 E4InputMultiState E4InputMultiState(E4InputFieldName_Intf name, java.lang.String label, E4InputMultiStateOptions selection)
           
 E4InputMultiValue E4InputMultiValue(PASSWORDFIELD basefield)
           
 E4InputMultiValue E4InputMultiValue(TEXTAREA basefield)
           
 E4InputMultiValue E4InputMultiValue(TEXTFIELD basefield)
           
 E4Fieldset FIELDSET()
          Create a E4Fieldset and add it to the element's vector for this FORM.
 FILESELECTION FILESELECTION(E4InputFieldName_Intf name, java.lang.String label, int displaylength)
           
 FILEUPLOAD FILEUPLOAD(E4InputFieldName_Intf name, E4Label_Intf label)
           
 FILEUPLOAD FILEUPLOAD(E4InputFieldName_Intf name, E4Label_Intf label, int displaylength)
           
 FILEUPLOAD FILEUPLOAD(E4InputFieldName_Intf name, java.lang.String label, int displaylength)
           
 E4Fieldset findFIELDSET()
          Find the first E4Fieldset which is contained in the FORM.
 E4Fieldset findFIELDSET(int id)
          Find the E4Fieldset which is specified by the given id.
 FLOATFIELD FLOATFIELD(E4InputFieldName_Intf name, E4Label_Intf label)
           
 FLOATFIELD FLOATFIELD(E4InputFieldName_Intf name, E4Label_Intf label, int displaylength, int decimals)
           
 FLOATFIELD FLOATFIELD(E4InputFieldName_Intf name, java.lang.String label)
           
 FLOATFIELD FLOATFIELD(E4InputFieldName_Intf name, java.lang.String label, int displaylength, int decimals)
           
 FORM_Reset FORM_Reset(E4Label_Intf label)
          Create and append a FORM_Reset button element, which causes the form to be cleared.
 FORM_Reset FORM_Reset(E4Label_Intf label, CLASS_Name style)
          Create and append a FORM_Reset button element, which causes the form to be cleared.
 FORM_Reset FORM_Reset(E4Label_Intf label, STYLE_Name style)
          Create and append a FORM_Reset button element, which causes the form to be cleared.
 FORM_Reset FORM_Reset(java.lang.String label)
          Create and append a FORM_Reset button element, which causes the form to be cleared.
 FORM_Reset FORM_Reset(java.lang.String label, CLASS_Name style)
          Create and append a FORM_Reset button element, which causes the form to be cleared.
 FORM_Reset FORM_Reset(java.lang.String label, STYLE_Name style)
          Create and append a FORM_Reset button element, which causes the form to be cleared.
 FORM_Submit FORM_Submit(E4Label_Intf label)
          Create and append a FORM_Submit button element, which causes the form to submit and call the specified method ( setAction(e4s.html.E4Method)).
 FORM_Submit FORM_Submit(E4Label_Intf label, CLASS_Name style)
          Create and append a FORM_Submit button element, which causes the form to submit and call the specified method ( setAction(e4s.html.E4Method)).
 FORM_Submit FORM_Submit(E4Label_Intf label, STYLE_Name style)
          Create and append a FORM_Submit button element, which causes the form to submit and call the specified method ( setAction(e4s.html.E4Method)).
 FORM_Submit FORM_Submit(java.lang.String label)
          Create and append a FORM_Submit button element, which causes the form to submit and call the specified method ( setAction(e4s.html.E4Method)).
 FORM_Submit FORM_Submit(java.lang.String label, CLASS_Name style)
          Create and append a FORM_Submit button element, which causes the form to submit and call the specified method ( setAction(e4s.html.E4Method)).
 FORM_Submit FORM_Submit(java.lang.String label, STYLE_Name style)
          Create and append a FORM_Submit button element, which causes the form to submit and call the specified method ( setAction(e4s.html.E4Method)).
 java.lang.String getEncryptionType()
          Gets the encryption type of this FORM element.
 E4Color getFocusBgColor()
           
static E4Color getFocusBgColorDefault()
           
 java.lang.String getName()
          Name of this <FROM>.
 E4FrameName getTarget()
          Get the target frame.
 HIDDENFIELD HIDDENFIELD(E4InputFieldName_Intf name)
           
 HIDDENFIELD HIDDENFIELD(E4InputFieldName_Intf name, boolean value)
           
 HIDDENFIELD HIDDENFIELD(E4InputFieldName_Intf name, java.util.Date value)
           
 HIDDENFIELD HIDDENFIELD(E4InputFieldName_Intf name, E4Long value)
           
 HIDDENFIELD HIDDENFIELD(E4InputFieldName_Intf name, E4String value)
           
 HIDDENFIELD HIDDENFIELD(E4InputFieldName_Intf name, int value)
           
 HIDDENFIELD HIDDENFIELD(E4InputFieldName_Intf name, long value)
           
 HIDDENFIELD HIDDENFIELD(E4InputFieldName_Intf name, java.lang.String value)
           
 LABEL LABEL(E4InputField_Intf field)
           
 LABEL LABEL(E4InputFieldName_Intf for_name, E4Label_Intf label)
           
 LONGFIELD LONGFIELD(E4InputFieldName_Intf name, E4Label_Intf label)
           
 LONGFIELD LONGFIELD(E4InputFieldName_Intf name, E4Label_Intf label, int displaylength)
           
 LONGFIELD LONGFIELD(E4InputFieldName_Intf name, java.lang.String label)
           
 LONGFIELD LONGFIELD(E4InputFieldName_Intf name, java.lang.String label, int displaylength)
           
 PASSWORDFIELD PASSWORDFIELD(E4InputFieldName_Intf name, E4Label_Intf label)
           
 PASSWORDFIELD PASSWORDFIELD(E4InputFieldName_Intf name, E4Label_Intf label, int displaylength)
           
 PASSWORDFIELD PASSWORDFIELD(E4InputFieldName_Intf name, java.lang.String label)
           
 PASSWORDFIELD PASSWORDFIELD(E4InputFieldName_Intf name, java.lang.String label, int displaylength)
           
 SELECT SELECT(E4InputFieldName_Intf name, E4Label_Intf label, E4SelectValues selection)
           
 SELECT SELECT(E4InputFieldName_Intf name, E4Label_Intf label, java.lang.String[] selection)
           
 SELECT SELECT(E4InputFieldName_Intf name, E4Label_Intf label, java.util.Vector selection)
          Deprecated.  
 SELECT SELECT(E4InputFieldName_Intf name, java.lang.String label, E4SelectValues selection)
           
 SELECT SELECT(E4InputFieldName_Intf name, java.lang.String label, java.lang.String[] selection)
           
 SELECT SELECT(E4InputFieldName_Intf name, java.lang.String label, java.util.Vector selection)
          Deprecated.  
 void setAcceptCharset(java.lang.String charset)
           
 void setAction(E4Method mref)
           
 void setAction(java.lang.String url)
           
 void setDecimalSign(E4DecimalSign decimalsign)
          Sets the decimal sign for all FLOATFIELD input fields on this form
 void setEncryptionType_Multidata()
          Sets the encryption type to multidata as used for file uploads.
 void setEncryptionType(java.lang.String encryption_type)
          Sets the encryption type of this FORM element.
 void setEventHandler(E4EventHandlerFORM handler)
          Set an event handler.
 void setFocusBgColor(E4Color bgcolor)
          Set the background color for focus highlighting on input.
static void setFocusBgColorDefault(E4Color bgcolor)
          Set the background color for focus highlighting on input.
 void setMethod_Get()
           
 void setMethod_Post()
           
 void setSTYLE(CLASS_Name class_name)
           
 void setTarget(E4FrameName target)
          Sets the frame (or window) target.
 void setTarget(FRAME target)
          Sets the frame (or window) target.
 TEXTAREA TEXTAREA(E4InputFieldName_Intf name, E4Label_Intf label, int cols, int rows)
           
 TEXTAREA TEXTAREA(E4InputFieldName_Intf name, java.lang.String label, int cols, int rows)
           
 TEXTFIELD TEXTFIELD(E4DBColumnInfo name, E4Label_Intf label)
           
 TEXTFIELD TEXTFIELD(E4DBColumnInfo name, java.lang.String label)
           
 TEXTFIELD TEXTFIELD(E4InputFieldName_Intf name, E4Label_Intf label, int displaylength)
           
 TEXTFIELD TEXTFIELD(E4InputFieldName_Intf name, E4Label_Intf label, int displaylength, int inputlength)
           
 TEXTFIELD TEXTFIELD(E4InputFieldName_Intf name, java.lang.String label, int displaylength)
           
 TEXTFIELD TEXTFIELD(E4InputFieldName_Intf name, java.lang.String label, int displaylength, int inputlength)
           
 void toHIDDENFIELD(E4CgiParams params)
          Adds all values within the parametes as HIDDENFIELD to the current form object.
 void toHIDDENFIELD(E4CgiParams params, E4InputFieldName_Intf[] except)
          Adds all values within the parametes as HIDDENFIELD to the current form object.
 void toHtml(E4StringBufferHtml buf, E4ServletImplementation_Intf servlet)
          Create the HTML output for this element.
 java.lang.String toString()
           
 boolean validate(E4CgiParams params, E4ServletImplementation_Intf servlet)
          Run throught all child elements recursivly, and if those elements implement interface E4InputField_Intf then store the parameter and execute the E4InputField_Intf.validate() function.
 
Methods inherited from class e4s.html.E4HtmlContentElementPersistant
preventFromRemoving, preventFromRemoving, removeAll, toDebug
 
Methods inherited from class e4s.html.E4HtmlContentElement
A_Email, A_Email, A_Multiple, A_Popup, A_Popup, A_Popup, A_Popup, A_Popup, A_Popup, A_Popup, A_Reference, A_Reference, A_Reference, A_Reference, A_Reference, A_ReturnValue, A_ReturnValue, A_ReturnValue, A_ReturnValue, A, A, A, A, A, A, A, AjaxElement, AjaxElement, AjaxElement, B, B, BIG, Box, Box, Box, BoxRoundCorners, BoxRoundCorners, BoxRoundCorners, BR, BUTTON, BUTTON, BUTTON, BUTTON, BUTTON, BUTTON, BUTTON, BUTTON, BUTTON, BUTTON, BUTTON, BUTTON, BUTTON, CENTER, DEL, DIV, DIV, DIV, DIV, FONT, FONT, FONT, FONT, FONT, FONT, FONT, FONT, FONT, FONT, FONT, FONT, FONT, FONT, FONT, FullSizeE4Message, H1, H2, H3, H4, Hint, HR, I, I, IMG, IMG, IMG, IMG, IMG, IMG, IMG, IMG, INS, Message, Message, Message, Message, Message, NBSP, NOBR, P_NBSP, P, PRE, print, print, print, print, print, print, print, print, print, print, print, print, print, print, print, print, print, println, println, println, println, println, println, println, rem, rem, rem, rem, rem, rem, SMALL, SPAN, STRIKE, strike, SystemError, SystemError, SystemError, SystemError, TABLE, TABLE, trace, trace, trace, trace, trace, trace, translate_Sys, translate, U, UL
 
Methods inherited from class e4s.html.E4HtmlElement
addElement, addElement, copyElements, print
 
Methods inherited from class e4s.html.E4HtmlElementGeneral
addScript, addScript, addScript, addStyleForEditing, addTranslationForEditing, buildStyleAttribute, buildStyleClassReference, collectScripts, collectStylesForEditing, collectStylesForEditing, collectStylesForEditing, collectTranslationsForEditing, collectTranslationsForEditing, createScript, createScript, debugToString, findElement, findElement, findElement, findElement, getElements, getElementsVec, getField, getId, getLastElement, getStringContent, getStyle, getSTYLE, getStyle, hasScripts, hasSTYLE, isContentClass, isE4InputField_Intf, openTag, removeElementById, removeElements, removeElements, removeStyle, setId, setReadOnly, setStyle, setStyle, setSTYLE, setValue, Style, Style, toHtml_hidden
 
Methods inherited from class e4s.html.E4HtmlObject
E4ID, set_e4sID
 
Methods inherited from class e4s.util.E4Object
Calendar, CName, CName, E4LabelApp, E4LabelApp, E4LabelApp, E4LabelApp, E4LabelApp, E4LabelApp, E4LabelNone, E4LabelNone, E4LabelNone, E4LabelNone, E4LabelSys, E4LabelSys, e4sCopyright, e4sVersion, encode, encode, encode, encodeHtml, encodeHtml, encodeHtml, encodeURL, encodeURL, encodeURL, finalize, getLINE, getTRACE, getTRACE, getTRACE, getTRACE, getTRACE, getTRACE, getTraceMemory, HtmlEncode, HtmlEncode, HtmlEncode, isdecimal, isdigit, isnotok, isnotok, isnumeric, isok, isok, isok, isok, lastCallingFunction, lastCallingFunction, lastCallingFunction, lastCallingFunction, lastCallingStack, mkdirs, null2nbsp, null2nbsp, null2nbsp, ok, ok, ok, ok, outPrintln, setLogFile4Trace, setTraceMemory, STACKTRACE, toDouble, toFloat, toFloat, TRACE_CALLS, TRACE, TRACE, TRACE, TRACE, TRACE, TRACE, TRACE, TRACE, TRACE, TRACE, TRACE, TRACE, wait
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface e4s.html.E4HtmlElement_Intf
addScript, addScript, addScript, collectScripts, collectStylesForEditing, collectTranslationsForEditing, debugToString, findElement, findElement, getElements, getElementsVec, getField, getId, getStringContent, isContentClass, removeAll, removeElementById, removeElements, set_e4sID, setId, setReadOnly, setValue, toHtml_hidden
 

Field Detail

DEFAULTSTYLE

public static STYLE_Name DEFAULTSTYLE

ENCRYPTION_MULTIPART_FORM_DATA

public static final java.lang.String ENCRYPTION_MULTIPART_FORM_DATA
A encryption type for multidata requests (used to upload files)

See Also:
setEncryptionType_Multidata(), setEncryptionType(java.lang.String), getEncryptionType(), Constant Field Values

JS_SUBMIT_CLIENT

public static final java.lang.String JS_SUBMIT_CLIENT
See Also:
Constant Field Values

JS_FORM_HANDLING

public static final java.lang.String JS_FORM_HANDLING
See Also:
Constant Field Values
Constructor Detail

FORM

public FORM(java.lang.String name)

FORM

public FORM(E4ID parent_id,
            java.lang.String name)

FORM

public FORM(E4ID parent_id)

FORM

public FORM()

FORM

public FORM(E4ID parent_id,
            E4Method mref)

FORM

public FORM(E4Method mref)
Method Detail

setAction

public void setAction(E4Method mref)

setAction

public void setAction(java.lang.String url)

FIELDSET

public E4Fieldset FIELDSET()
Create a E4Fieldset and add it to the element's vector for this FORM.

Returns:
the new created E4Fieldset
See Also:
findFIELDSET(int)

BUTTON_Submit

public BUTTON BUTTON_Submit(E4Label_Intf label)

BUTTON_Submit

public BUTTON BUTTON_Submit(java.lang.String label)

BUTTON_Submit

public BUTTON BUTTON_Submit()

BUTTON_Reset

public BUTTON BUTTON_Reset(E4Label_Intf label)

BUTTON_Reset

public BUTTON BUTTON_Reset(java.lang.String label)

BUTTON_Reset

public BUTTON BUTTON_Reset()

BUTTON

public BUTTON BUTTON(E4Label_Intf label,
                     char type)

BUTTON

public BUTTON BUTTON(java.lang.String label,
                     char type)

BUTTON

public BUTTON BUTTON(char type)

BasicTextInput

public E4BasicTextInput BasicTextInput(java.lang.String name)
Deprecated. 


TEXTFIELD

public TEXTFIELD TEXTFIELD(E4InputFieldName_Intf name,
                           java.lang.String label,
                           int displaylength)

TEXTFIELD

public TEXTFIELD TEXTFIELD(E4InputFieldName_Intf name,
                           java.lang.String label,
                           int displaylength,
                           int inputlength)

TEXTFIELD

public TEXTFIELD TEXTFIELD(E4InputFieldName_Intf name,
                           E4Label_Intf label,
                           int displaylength,
                           int inputlength)

TEXTFIELD

public TEXTFIELD TEXTFIELD(E4DBColumnInfo name,
                           E4Label_Intf label)

TEXTFIELD

public TEXTFIELD TEXTFIELD(E4DBColumnInfo name,
                           java.lang.String label)

TEXTFIELD

public TEXTFIELD TEXTFIELD(E4InputFieldName_Intf name,
                           E4Label_Intf label,
                           int displaylength)

FILEUPLOAD

public FILEUPLOAD FILEUPLOAD(E4InputFieldName_Intf name,
                             java.lang.String label,
                             int displaylength)

FILEUPLOAD

public FILEUPLOAD FILEUPLOAD(E4InputFieldName_Intf name,
                             E4Label_Intf label)

FILEUPLOAD

public FILEUPLOAD FILEUPLOAD(E4InputFieldName_Intf name,
                             E4Label_Intf label,
                             int displaylength)

FILESELECTION

public FILESELECTION FILESELECTION(E4InputFieldName_Intf name,
                                   java.lang.String label,
                                   int displaylength)

PASSWORDFIELD

public PASSWORDFIELD PASSWORDFIELD(E4InputFieldName_Intf name,
                                   java.lang.String label,
                                   int displaylength)

PASSWORDFIELD

public PASSWORDFIELD PASSWORDFIELD(E4InputFieldName_Intf name,
                                   E4Label_Intf label,
                                   int displaylength)

PASSWORDFIELD

public PASSWORDFIELD PASSWORDFIELD(E4InputFieldName_Intf name,
                                   java.lang.String label)

PASSWORDFIELD

public PASSWORDFIELD PASSWORDFIELD(E4InputFieldName_Intf name,
                                   E4Label_Intf label)

LONGFIELD

public LONGFIELD LONGFIELD(E4InputFieldName_Intf name,
                           java.lang.String label,
                           int displaylength)

LONGFIELD

public LONGFIELD LONGFIELD(E4InputFieldName_Intf name,
                           java.lang.String label)

LONGFIELD

public LONGFIELD LONGFIELD(E4InputFieldName_Intf name,
                           E4Label_Intf label,
                           int displaylength)

LONGFIELD

public LONGFIELD LONGFIELD(E4InputFieldName_Intf name,
                           E4Label_Intf label)

DATEFIELD

public DATEFIELD DATEFIELD(E4InputFieldName_Intf name,
                           java.lang.String label)

DATEFIELD

public DATEFIELD DATEFIELD(E4InputFieldName_Intf name,
                           E4Label_Intf label)

DATEFIELD

public DATEFIELD DATEFIELD(E4InputFieldName_Intf name,
                           java.lang.String label,
                           boolean default_pickup)

LABEL

public LABEL LABEL(E4InputFieldName_Intf for_name,
                   E4Label_Intf label)

LABEL

public LABEL LABEL(E4InputField_Intf field)

SELECT

public SELECT SELECT(E4InputFieldName_Intf name,
                     java.lang.String label,
                     java.util.Vector selection)
Deprecated. 

See Also:
SELECT( e4s.html.input.extended.E4InputFieldName_Intf name, String, e4s.html.input.extended.E4SelectValues )

SELECT

public SELECT SELECT(E4InputFieldName_Intf name,
                     java.lang.String label,
                     E4SelectValues selection)

SELECT

public SELECT SELECT(E4InputFieldName_Intf name,
                     E4Label_Intf label,
                     java.util.Vector selection)
Deprecated. 

See Also:
SELECT( e4s.html.input.extended.E4InputFieldName_Intf name, e4s.translate.E4Label_Intf, e4s.html.input.extended.E4SelectValues )

SELECT

public SELECT SELECT(E4InputFieldName_Intf name,
                     E4Label_Intf label,
                     E4SelectValues selection)

SELECT

public SELECT SELECT(E4InputFieldName_Intf name,
                     java.lang.String label,
                     java.lang.String[] selection)

SELECT

public SELECT SELECT(E4InputFieldName_Intf name,
                     E4Label_Intf label,
                     java.lang.String[] selection)

FLOATFIELD

public FLOATFIELD FLOATFIELD(E4InputFieldName_Intf name,
                             java.lang.String label,
                             int displaylength,
                             int decimals)

FLOATFIELD

public FLOATFIELD FLOATFIELD(E4InputFieldName_Intf name,
                             E4Label_Intf label,
                             int displaylength,
                             int decimals)

FLOATFIELD

public FLOATFIELD FLOATFIELD(E4InputFieldName_Intf name,
                             java.lang.String label)

FLOATFIELD

public FLOATFIELD FLOATFIELD(E4InputFieldName_Intf name,
                             E4Label_Intf label)

TEXTAREA

public TEXTAREA TEXTAREA(E4InputFieldName_Intf name,
                         java.lang.String label,
                         int cols,
                         int rows)

TEXTAREA

public TEXTAREA TEXTAREA(E4InputFieldName_Intf name,
                         E4Label_Intf label,
                         int cols,
                         int rows)

CHECKBOX

public CHECKBOX CHECKBOX(E4InputFieldName_Intf name,
                         java.lang.String label)

CHECKBOX

public CHECKBOX CHECKBOX(E4InputFieldName_Intf name,
                         E4Label_Intf label)

HIDDENFIELD

public HIDDENFIELD HIDDENFIELD(E4InputFieldName_Intf name)

HIDDENFIELD

public HIDDENFIELD HIDDENFIELD(E4InputFieldName_Intf name,
                               java.lang.String value)

HIDDENFIELD

public HIDDENFIELD HIDDENFIELD(E4InputFieldName_Intf name,
                               boolean value)

HIDDENFIELD

public HIDDENFIELD HIDDENFIELD(E4InputFieldName_Intf name,
                               long value)

HIDDENFIELD

public HIDDENFIELD HIDDENFIELD(E4InputFieldName_Intf name,
                               E4Long value)

HIDDENFIELD

public HIDDENFIELD HIDDENFIELD(E4InputFieldName_Intf name,
                               E4String value)

HIDDENFIELD

public HIDDENFIELD HIDDENFIELD(E4InputFieldName_Intf name,
                               int value)

HIDDENFIELD

public HIDDENFIELD HIDDENFIELD(E4InputFieldName_Intf name,
                               java.util.Date value)
                        throws java.lang.Exception
Throws:
java.lang.Exception

toHIDDENFIELD

public void toHIDDENFIELD(E4CgiParams params,
                          E4InputFieldName_Intf[] except)
                   throws java.lang.Exception
Adds all values within the parametes as HIDDENFIELD to the current form object. Ignores values for E4Constants.PARAM_TIMESTAMP, E4Constants.PARAM_PRESERVED and E4ServletImplementation_Intf.PARAM_FUNCTION. There is no check, if the paramater is already included in that form or if any field is added later, then it will be a possible case that one or more parameters are twice in this form which will cause uncertain overwriting values at the next call!

Parameters:
params - the parameters to be added.
Throws:
java.lang.Exception
See Also:
HIDDENFIELD, toHIDDENFIELD(e4s.html.E4giParams)

toHIDDENFIELD

public void toHIDDENFIELD(E4CgiParams params)
                   throws java.lang.Exception
Adds all values within the parametes as HIDDENFIELD to the current form object. Ignores values for E4Constants.PARAM_TIMESTAMP, E4Constants.PARAM_PRESERVED and E4ServletImplementation_Intf.PARAM_FUNCTION. There is no check, if the paramater is already included in that form or if any field is added later, then it will be a possible case that one or more parameters are twice in this form which will cause uncertain overwriting values at the next call!

Parameters:
params - the parameters to be added.
Throws:
java.lang.Exception
See Also:
HIDDENFIELD, toHIDDENFIELD(e4s.html.E4giParams, e4s.html.input.extended.E4InputFieldName_Intf[])

E4InputMultiState

public E4InputMultiState E4InputMultiState(E4InputFieldName_Intf name,
                                           E4Label_Intf label,
                                           E4InputMultiStateOptions selection)

E4InputMultiState

public E4InputMultiState E4InputMultiState(E4InputFieldName_Intf name,
                                           java.lang.String label,
                                           E4InputMultiStateOptions selection)

E4InputMultiValue

public E4InputMultiValue E4InputMultiValue(TEXTAREA basefield)

E4InputMultiValue

public E4InputMultiValue E4InputMultiValue(TEXTFIELD basefield)

E4InputMultiValue

public E4InputMultiValue E4InputMultiValue(PASSWORDFIELD basefield)

FORM_Submit

public FORM_Submit FORM_Submit(java.lang.String label)
Create and append a FORM_Submit button element, which causes the form to submit and call the specified method ( setAction(e4s.html.E4Method)).

Parameters:
label - label for display
See Also:
FORM_Submit(String, STYLE_Name ), FORM_Reset(e4s.translate.E4Label_Intf)

FORM_Submit

public FORM_Submit FORM_Submit(E4Label_Intf label)
Create and append a FORM_Submit button element, which causes the form to submit and call the specified method ( setAction(e4s.html.E4Method)).

Parameters:
label - label for display
See Also:
FORM_Submit(String, STYLE_Name ), FORM_Reset(e4s.translate.E4Label_Intf)

FORM_Submit

public FORM_Submit FORM_Submit(java.lang.String label,
                               STYLE_Name style)
Create and append a FORM_Submit button element, which causes the form to submit and call the specified method ( setAction(e4s.html.E4Method)).

Parameters:
label - label for display
style - style to be assigned to the FORM_Submit element, can be null
See Also:
FORM_Submit(String ), FORM_Reset(e4s.translate.E4Label_Intf)

FORM_Submit

public FORM_Submit FORM_Submit(E4Label_Intf label,
                               STYLE_Name style)
Create and append a FORM_Submit button element, which causes the form to submit and call the specified method ( setAction(e4s.html.E4Method)).

Parameters:
label - label for display
style - style to be assigned to the FORM_Submit element, can be null
See Also:
FORM_Submit(String ), #FORM_Reset()

FORM_Submit

public FORM_Submit FORM_Submit(java.lang.String label,
                               CLASS_Name style)
Create and append a FORM_Submit button element, which causes the form to submit and call the specified method ( setAction(e4s.html.E4Method)).

Parameters:
label - label for display
style - style to be assigned to the FORM_Submit element, can be null
See Also:
FORM_Submit(String ), #FORM_Reset()

FORM_Submit

public FORM_Submit FORM_Submit(E4Label_Intf label,
                               CLASS_Name style)
Create and append a FORM_Submit button element, which causes the form to submit and call the specified method ( setAction(e4s.html.E4Method)).

Parameters:
label - label for display
style - style to be assigned to the FORM_Submit element, can be null
See Also:
FORM_Submit(String ), #FORM_Reset()

FORM_Reset

public FORM_Reset FORM_Reset(E4Label_Intf label)
Create and append a FORM_Reset button element, which causes the form to be cleared.

Parameters:
label - label for display
See Also:
FORM_Submit(java.lang.String), FORM_Reset(String, STYLE_Name )

FORM_Reset

public FORM_Reset FORM_Reset(java.lang.String label)
Create and append a FORM_Reset button element, which causes the form to be cleared.

Parameters:
label - label for display
See Also:
FORM_Submit(java.lang.String), FORM_Reset(String, STYLE_Name )

FORM_Reset

public FORM_Reset FORM_Reset(java.lang.String label,
                             STYLE_Name style)
Create and append a FORM_Reset button element, which causes the form to be cleared.

Parameters:
label - label for display
style - style to be assigned to the FORM_Reset element, can be null
See Also:
FORM_Submit(java.lang.String), FORM_Reset(String )

FORM_Reset

public FORM_Reset FORM_Reset(E4Label_Intf label,
                             STYLE_Name style)
Create and append a FORM_Reset button element, which causes the form to be cleared.

Parameters:
label - label for display
style - style to be assigned to the FORM_Reset element, can be null
See Also:
FORM_Submit(java.lang.String), FORM_Reset(String )

FORM_Reset

public FORM_Reset FORM_Reset(java.lang.String label,
                             CLASS_Name style)
Create and append a FORM_Reset button element, which causes the form to be cleared.

Parameters:
label - label for display
style - style to be assigned to the FORM_Reset element, can be null
See Also:
FORM_Submit(java.lang.String), FORM_Reset(String )

FORM_Reset

public FORM_Reset FORM_Reset(E4Label_Intf label,
                             CLASS_Name style)
Create and append a FORM_Reset button element, which causes the form to be cleared.

Parameters:
label - label for display
style - style to be assigned to the FORM_Reset element, can be null
See Also:
FORM_Submit(java.lang.String), FORM_Reset(String )

addElement

public void addElement(E4Fieldset fieldset)

addElement

public void addElement(E4HtmlElement_Intf element)
Description copied from class: E4HtmlElement
Adds an element to the internal Vector.

Overrides:
addElement in class E4HtmlElement
Parameters:
element - the element to be added

setDecimalSign

public void setDecimalSign(E4DecimalSign decimalsign)
Sets the decimal sign for all FLOATFIELD input fields on this form

Parameters:
decimalsign - a character, typically '.' or ','

getName

public java.lang.String getName()
Name of this <FROM>.

Returns:
name of the form

toHtml

public void toHtml(E4StringBufferHtml buf,
                   E4ServletImplementation_Intf servlet)
            throws java.lang.Exception
Description copied from interface: E4HtmlElement_Intf
Create the HTML output for this element. Also run throught all child elements, and call their E4HtmlElement_Intf.toHtml(e4s.util.E4StringBufferHtml, e4s.servlet.E4ServletImplementation_Intf) function to generate output of those objects which becomes appended. Normally, there is no need to call this function anyway, and this also might result in side effects of too-early relasing of objects in some cases. This function is called by E4ServletImplementation_Intf.write(e4s.html.E4HtmlElement) on the top level HTML element (common this is a HTML or BODY element) and branches down to all child elements.

Specified by:
toHtml in interface E4HtmlElement_Intf
Overrides:
toHtml in class E4HtmlElementGeneral
Parameters:
servlet - is the servlet context which can be retrieved using the E4ModuleImplementation.getServlet().
Throws:
java.lang.Exception

setEventHandler

public void setEventHandler(E4EventHandlerFORM handler)
Set an event handler.

Parameters:
handler - the event-handle

createFormScript

public static E4JavaScript createFormScript()

getFocusBgColorDefault

public static E4Color getFocusBgColorDefault()

getFocusBgColor

public E4Color getFocusBgColor()

setFocusBgColorDefault

public static void setFocusBgColorDefault(E4Color bgcolor)
Set the background color for focus highlighting on input.

Parameters:
bgcolor - null to turn off the highlighting, or any other value
See Also:
getFocusBgColor()

setFocusBgColor

public void setFocusBgColor(E4Color bgcolor)
Set the background color for focus highlighting on input.

Parameters:
bgcolor - null to turn off the highlighting, or any other value
See Also:
getFocusBgColor()

E4ID

public E4ID E4ID()
Description copied from class: E4HtmlObject
Get the E4ID of the object. The E4ID is a unique identifier for an nested HTML element, it can be either the name of the class or any previous assigned string.

Overrides:
E4ID in class E4HtmlObject
Returns:
the E4ID
See Also:
E4HtmlObject.E4ID(String), E4HtmlObject.set_e4sID(e4s.util.E4ID)

setEncryptionType

public void setEncryptionType(java.lang.String encryption_type)
Sets the encryption type of this FORM element.

Parameters:
encryption_type - the encryption type of the form, a value of null means specifies no encryption type.
See Also:
getEncryptionType(), setEncryptionType_Multidata(), ENCRYPTION_MULTIPART_FORM_DATA

setEncryptionType_Multidata

public void setEncryptionType_Multidata()
Sets the encryption type to multidata as used for file uploads.

See Also:
setEncryptionType(java.lang.String), getEncryptionType(), ENCRYPTION_MULTIPART_FORM_DATA

getEncryptionType

public java.lang.String getEncryptionType()
Gets the encryption type of this FORM element.

Returns:
the encryption type of the form, a value of null means specifies no encryption type
See Also:
setEncryptionType(java.lang.String), ENCRYPTION_MULTIPART_FORM_DATA

setMethod_Post

public void setMethod_Post()

setMethod_Get

public void setMethod_Get()

setTarget

public void setTarget(E4FrameName target)
Sets the frame (or window) target.

Parameters:
target - the target window or name of the target frame
See Also:
setTarget(e4s.html.FRAME), setTarget(e4s.html.E4FrameName), FRAME.getFrameName(), getTarget()

setTarget

public void setTarget(FRAME target)
Sets the frame (or window) target. Same as setTarget(target.getFrameName());

Parameters:
target - the frame
See Also:
setTarget(e4s.html.E4FrameName), A.setTarget(e4s.html.E4FrameName), getTarget()

setAcceptCharset

public void setAcceptCharset(java.lang.String charset)

getTarget

public E4FrameName getTarget()
Get the target frame.

Returns:
null, if no target frame is defined (means that this link goes to the current document/window of the browser. Othervise the frame name.
See Also:
setTarget(e4s.html.E4FrameName)

validate

public boolean validate(E4CgiParams params,
                        E4ServletImplementation_Intf servlet)
                 throws java.lang.Exception
Run throught all child elements recursivly, and if those elements implement interface E4InputField_Intf then store the parameter and execute the E4InputField_Intf.validate() function. In any case, you can use this function as well to set values out of the E4CgiParams to the E4InputField_Intf objects. Example:
 public E4Method start(HTML html)
 {
    // create the form, call method save
    FORM form = html.FORM(save);
    
    // add a field, declare a validator
    TEXTFIELD fTxt = form.TEXTFIELD(new E4InputFieldName("TEST"), "Testfield", 20);
    fTxt.setValidator(new E4ValidatorNoBlanks());
    
    // important when persistancing FORM objects
    form.preventFromRemoving();
    
    // persist that form object
    setSessionObject("MySessionObject", form);
    
    form.BUTTON_Submit("Save");
 }
 
 public E4Method save(HTML html, E4CgiParams params)
 {
    FORM form = (FORM) getSessionObject("MySessionObject");
    
    if (!form.validate(params))
    {
       html.addElement(form);
    }
    else
    {
       // continue save
    }
 }
 

Specified by:
validate in interface E4HtmlElement_Intf
Overrides:
validate in class E4HtmlElementGeneral
Parameters:
params - the current cgi parameters
Returns:
true, if all defined validations will return true. false, if at least one validation returns false. Note, that in any case all validations must be performed to set the fields error-messages.
Throws:
java.lang.Exception
See Also:
e4s.html.input.extended.E4InputField.setValidator, E4InputField_Intf.validate(), e4s.html.input.extended.E4HtmlElementGeneral#validate, e4s.html.E4HtmlElementPersistant.preventFromRemoving(), E4ModuleImplementation.getSessionObject(java.lang.String)

findFIELDSET

public E4Fieldset findFIELDSET(int id)
Find the E4Fieldset which is specified by the given id. The id must be assigned to that E4Fieldset using the E4HtmlElementGeneral.setId(int) function.

Parameters:
id - the id of the fieldset
Returns:
null if not found or the E4Fieldset
See Also:
findFIELDSET(), #E4Fieldset, E4HtmlElementGeneral.setId(int), e4s.html.findElement

findFIELDSET

public E4Fieldset findFIELDSET()
Find the first E4Fieldset which is contained in the FORM. This only works for forms having just one E4Fieldset element, for cases where multiple FIELDSETS are used within one form, use findFIELDSET(int).

Parameters:
id - the id of the fieldset
Returns:
null if not found or the E4Fieldset
See Also:
findFIELDSET(int), #E4Fieldset, E4HtmlElementGeneral.findElement(Class)

toString

public java.lang.String toString()
Overrides:
toString in class E4Object

setSTYLE

public void setSTYLE(CLASS_Name class_name)

_getSVNVersionString

public static java.lang.String _getSVNVersionString()
Get version info string from subversion.

Returns:
the version info string.
See Also:
E4Util.getRevisionCodeFromSVN(Class)

www.element4solution.com