| 
JSF-Spring | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjavax.faces.component.UIComponent
javax.faces.component.UIComponentBase
javax.faces.component.UIForm
javax.faces.component.html.HtmlForm
de.mindmatters.faces.component.html.HtmlForm
public class HtmlForm
Represents an HTML form element. HtmlForm implements
 ActionSource - therefore it is possible to define an action and an
 action listener attribute. Methodbindings declared as action listener will be
 invoked on every form submit before action listeners of
 any nested UICommand will be executed.
 Futhermore this form supports stateless action listeners as direct children
 and the immediate attribute.
 
 
 HtmlForm supports the "method" attribute.
 Supported methods are 'POST' (default method) and 'GET'. 'GET' is
 only supported if an appropriate ViewBuilder is
 configured as ViewHandler.
 
 By default, the rendererType property must be set to
 "de.mindmatters.faces.Form". This value can be changed by
 calling the setRendererType() method.
 
| Field Summary | |
|---|---|
static java.lang.String | 
COMPONENT_FAMILY
The standard component type for this component.  | 
static java.lang.String | 
COMPONENT_TYPE
The standard component type for this component.  | 
static java.lang.String | 
RENDERER_TYPE
The standard renderer type for this component.  | 
| Fields inherited from interface javax.faces.component.NamingContainer | 
|---|
SEPARATOR_CHAR | 
| Constructor Summary | |
|---|---|
HtmlForm()
The standard constructor.  | 
|
| Method Summary | |
|---|---|
 void | 
addActionListener(ActionListener listener)
 | 
 void | 
broadcast(FacesEvent event)
Invoke any listeners attached to this object which are listening for an event whose type matches the specified event's runtime type.  | 
 MethodBinding | 
getAction()
 | 
 MethodBinding | 
getActionListener()
 | 
 ActionListener[] | 
getActionListeners()
 | 
 java.lang.String | 
getMethod()
Returns the method of this form - supports 'POST' or 'GET'.  | 
 boolean | 
isImmediate()
 | 
 boolean | 
isTransient()
 | 
 void | 
queueEvent(FacesEvent e)
 | 
 void | 
removeActionListener(ActionListener listener)
 | 
 void | 
restoreState(FacesContext context,
             java.lang.Object state)
Invoked in the "restore view" phase, this initialises this object's members from the values saved previously into the provided state object.  | 
 java.lang.Object | 
saveState(FacesContext context)
Invoked after the render phase has completed, this method returns an object which can be passed to the restoreState of some other instance of UIComponentBase to reset that object's state to the same values as this object currently has.  | 
 void | 
setAction(MethodBinding action)
 | 
 void | 
setActionListener(MethodBinding actionListener)
 | 
 void | 
setId(java.lang.String id)
Set an identifier for this component which is unique within the scope of the nearest ancestor NamingContainer component.  | 
 void | 
setImmediate(boolean immediate)
 | 
 void | 
setMethod(java.lang.String method)
Sets the method of this form - supports 'POST' or 'GET'.  | 
 void | 
setTransient(boolean transientFlag)
 | 
| Methods inherited from class javax.faces.component.html.HtmlForm | 
|---|
getAccept, getAcceptcharset, getDir, getEnctype, getLang, getOnclick, getOndblclick, getOnkeydown, getOnkeypress, getOnkeyup, getOnmousedown, getOnmousemove, getOnmouseout, getOnmouseover, getOnmouseup, getOnreset, getOnsubmit, getStyle, getStyleClass, getTarget, getTitle, setAccept, setAcceptcharset, setDir, setEnctype, setLang, setOnclick, setOndblclick, setOnkeydown, setOnkeypress, setOnkeyup, setOnmousedown, setOnmousemove, setOnmouseout, setOnmouseover, setOnmouseup, setOnreset, setOnsubmit, setStyle, setStyleClass, setTarget, setTitle | 
| Methods inherited from class javax.faces.component.UIForm | 
|---|
getFamily, isSubmitted, processDecodes, processUpdates, processValidators, setSubmitted | 
| Methods inherited from class javax.faces.component.UIComponentBase | 
|---|
addFacesListener, decode, encodeBegin, encodeChildren, encodeEnd, findComponent, getAttributes, getChildCount, getChildren, getClientId, getFacesContext, getFacesListeners, getFacet, getFacets, getFacetsAndChildren, getId, getParent, getRenderer, getRendererType, getRendersChildren, getValueBinding, isRendered, processRestoreState, processSaveState, removeFacesListener, restoreAttachedState, saveAttachedState, setParent, setRendered, setRendererType, setValueBinding | 
| Methods inherited from class java.lang.Object | 
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
| Field Detail | 
|---|
public static final java.lang.String RENDERER_TYPE
public static final java.lang.String COMPONENT_TYPE
public static final java.lang.String COMPONENT_FAMILY
| Constructor Detail | 
|---|
public HtmlForm()
| Method Detail | 
|---|
public MethodBinding getAction()
getAction in interface ActionSourcepublic void setAction(MethodBinding action)
setAction in interface ActionSourcepublic MethodBinding getActionListener()
getActionListener in interface ActionSourcepublic void setActionListener(MethodBinding actionListener)
setActionListener in interface ActionSourcepublic void addActionListener(ActionListener listener)
addActionListener in interface ActionSourcepublic ActionListener[] getActionListeners()
getActionListeners in interface ActionSourcepublic void removeActionListener(ActionListener listener)
removeActionListener in interface ActionSourcepublic void setImmediate(boolean immediate)
setImmediate in interface ActionSourcepublic boolean isImmediate()
isImmediate in interface ActionSourcepublic java.lang.String getMethod()
null if not setpublic void setMethod(java.lang.String method)
method - The method 'POST' or 'GET'public java.lang.Object saveState(FacesContext context)
saveState in interface StateHoldersaveState in class HtmlForm
public void restoreState(FacesContext context,
                         java.lang.Object state)
restoreState in interface StateHolderrestoreState in class HtmlFormstate - is an object previously returned by
 the saveState method of this class.public void queueEvent(FacesEvent e)
queueEvent in class UIComponentBasepublic void broadcast(FacesEvent event)
This method does not propagate the event up to parent components, ie listeners attached to parent components don't automatically get called.
If any of the listeners throws AbortProcessingException then that exception will prevent any further listener callbacks from occurring, and the exception propagates out of this method without alteration.
ActionEvent events are typically queued by the renderer associated with this component in its decode method; ValueChangeEvent events by the component's validate method. In either case the event's source property references a component. At some later time the UIViewRoot component iterates over its queued events and invokes the broadcast method on each event's source object.
broadcast in class UIComponentBaseevent - must not be null.public final void setId(java.lang.String id)
The id must start with an underscore if it is generated by the JSF framework, and must not start with an underscore if it has been specified by the user (eg in a JSP tag).
The first character of the id must be an underscore or letter. Following characters may be letters, digits, underscores or dashes.
Null is allowed as a parameter, and will reset the id to null.
The clientId of this component is reset by this method; see getClientId for more info.
setId in class UIComponentBasepublic final boolean isTransient()
isTransient in interface StateHolderisTransient in class UIComponentBasepublic final void setTransient(boolean transientFlag)
setTransient in interface StateHoldersetTransient in class UIComponentBase
  | 
JSF-Spring | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||