org.appng.formtags

## Class FormElement

- java.lang.Object
- - org.appng.formtags.FormElement

-     public class FormElement
      extends Object

  A `FormElement` represents one of the following HTML elements:
  - `<input>`
  - `<textarea>`
  - `<select>`
  - `<option>`
  To process a `FormElement`, two steps are necessary:
  1. set the text content of the `FormElement` by calling `setContent(String)`
  2. calling `processContent()`
  Author:
    Matthias Müller

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `static class` | `ErrorAware.ErrorAppender`
    `static class` | `FormElement.InputTag` Defines the possible HTML Tags that a `FormElement` can represent.
    `static class` | `FormElement.InputType` Defines the possible types for an HTML `<input>`-element

  - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected List<FormElement>` | `elements`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `String` | `getContent()`
    `List<FormElement>` | `getElements()`
    `String` | `getErrorClass()`
    `String` | `getErrorElementId()`
    `String` | `getErrorMessage()`
    `Form` | `getForm()`
    `FormData` | `getFormData()`
    `List<FormUpload>` | `getFormUploads()`
    `FormElement.InputTag` | `getInputTag()`
    `FormElement.InputType` | `getInputType()`
    `String` | `getMandatoryMessage()`
    `String` | `getName()`
    `List<String>` | `getRequestValues()`
    `String` | `getRule()`
    `String` | `getValue()`
    `boolean` | `hasErrors()`
    `boolean` | `hasValue()`
    `boolean` | `isForwardValidation()`
    `boolean` | `isMandatory()`
    `boolean` | `isValid()`
    `String` | `processContent()`
    `void` | `setContent(String content)`
    `void` | `setErrorClass(String errorClass)`
    `void` | `setErrorElementId(String errorElementId)`
    `void` | `setErrorMessage(String errorMessage)`
    `void` | `setForm(Form form)`
    `void` | `setFormData(FormData formData)`
    `void` | `setFormUploads(List<FormUpload> formUploads)`
    `void` | `setForwardValidation(boolean forwardValidation)`
    `void` | `setInputTag(FormElement.InputTag inputTag)`
    `void` | `setInputType(FormElement.InputType inputType)`
    `void` | `setMandatory(boolean mandatory)`
    `void` | `setMandatoryMessage(String mandatoryMessage)`
    `void` | `setName(String name)`
    `void` | `setRule(String rule)`
    `void` | `setValid(boolean valid)`
    `void` | `setValue(String value)`
    `String` | `toString()`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- - ### Field Detail

    - #### elements

          protected List<FormElement> elements

  - ### Method Detail

    - #### processContent

          public String processContent()

    - #### hasValue

          public boolean hasValue()

    - #### isMandatory

          public boolean isMandatory()

    - #### setMandatory

          public void setMandatory(boolean mandatory)

    - #### getRule

          public String getRule()

    - #### setRule

          public void setRule(String rule)

    - #### getErrorClass

          public String getErrorClass()

    - #### setErrorClass

          public void setErrorClass(String errorClass)

    - #### isForwardValidation

          public boolean isForwardValidation()

    - #### setForwardValidation

          public void setForwardValidation(boolean forwardValidation)

    - #### getValue

          public String getValue()

    - #### setValue

          public void setValue(String value)

    - #### getRequestValues

          public List<String> getRequestValues()

    - #### getContent

          public String getContent()

    - #### setContent

          public void setContent(String content)

    - #### getName

          public String getName()

    - #### setName

          public void setName(String name)

    - #### getErrorMessage

          public String getErrorMessage()

    - #### setErrorMessage

          public void setErrorMessage(String errorMessage)

    - #### getFormData

          public FormData getFormData()

    - #### setFormData

          public void setFormData(FormData formData)

    - #### getFormUploads

          public List<FormUpload> getFormUploads()

    - #### setFormUploads

          public void setFormUploads(List<FormUpload> formUploads)

    - #### isValid

          public boolean isValid()

    - #### setValid

          public void setValid(boolean valid)

    - #### getInputTag

          public FormElement.InputTag getInputTag()

    - #### setInputTag

          public void setInputTag(FormElement.InputTag inputTag)

    - #### getInputType

          public FormElement.InputType getInputType()

    - #### setInputType

          public void setInputType(FormElement.InputType inputType)

    - #### getMandatoryMessage

          public String getMandatoryMessage()

    - #### setMandatoryMessage

          public void setMandatoryMessage(String mandatoryMessage)

    - #### getErrorElementId

          public String getErrorElementId()

    - #### setErrorElementId

          public void setErrorElementId(String errorElementId)

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `Object`

    - #### hasErrors

          public boolean hasErrors()

    - #### getForm

          public Form getForm()

    - #### setForm

          public void setForm(Form form)

    - #### getElements

          public List<FormElement> getElements()

Copyright © 2011–2023 aiticon GmbH. All rights reserved.