com.ibm.xsp.component
Class UIFormEx

java.lang.Object
  extended by javax.faces.component.UIComponent
      extended by javax.faces.component.UIComponentBase
          extended by javax.faces.component.UIForm
              extended by com.ibm.xsp.component.UIFormEx
All Implemented Interfaces:
FacesDojoComponent, ThemeControl, javax.faces.component.NamingContainer, javax.faces.component.StateHolder
Direct Known Subclasses:
XspForm

public class UIFormEx
extends javax.faces.component.UIForm
implements ThemeControl, FacesDojoComponent

The superclass of XspForm (corresponding to the xp:form tag, used in the XPage source when the XPage root tag has createForm="false").

Represents an HTML form element. Child input components will be submitted unless they have been disabled.

Not intended to be subclassed.


Nested Class Summary
 
Nested classes/interfaces inherited from class javax.faces.component.UIComponentBase
javax.faces.component.UIComponentBase.AggregatedIterator, javax.faces.component.UIComponentBase.UnmodifiableIterator
 
Nested classes/interfaces inherited from class javax.faces.component.UIComponent
javax.faces.component.UIComponent.StateMap, javax.faces.component.UIComponent.StateMapEntry
 
Field Summary
static java.lang.String COMPONENT_TYPE
           
static java.lang.String RENDERER_TYPE
           
 
Fields inherited from class javax.faces.component.UIForm
COMPONENT_FAMILY
 
Fields inherited from class javax.faces.component.UIComponentBase
EMPTY_ITERATOR
 
Fields inherited from class javax.faces.component.UIComponent
_xspStateId
 
Fields inherited from interface javax.faces.component.NamingContainer
SEPARATOR_CHAR
 
Constructor Summary
UIFormEx()
          Create a new XFForm instance with default property values.
 
Method Summary
 void addDojoAttribute(DojoAttribute attribute)
          Add a dojo attribute to the set associated with this property.
 java.lang.String getAutocomplete()
           Return the value of the autocomplete property.
 java.lang.String getDir()
          Return the value of the dir property.
 java.util.List<DojoAttribute> getDojoAttributes()
           Return the value of the dojoAttributes property.
 java.lang.String getDojoType()
           Return the value of the dojoType property.
 java.lang.String getEnctype()
           Return the value of the enctype property.
 java.lang.String getStyleKitFamily()
          The styleKitFamily is basically the default themeId, to use if the "themeId" property is not set on this control instance in the XPage source.
 boolean isAutoForm()
          Indicates if this form has been auto created by the View.
 boolean isNestedForm()
          Defaults to false, this should be set to nestedForm="true" when the XPage designer wants to create a form that is nested within another HTML form.
 void restoreState(javax.faces.context.FacesContext context, java.lang.Object state)
           
 void save()
          Calling this method will cause all data sources contained within this form to have their contents saved and also have the associated data model removed from the associated bean manager.
 void save(boolean removeFromManager)
          Calling this method will cause all data sources contained within this form to have their contents saved and optionally have the associated data model removed from the associated bean manager.
 java.lang.Object saveState(javax.faces.context.FacesContext context)
           
 void setAutocomplete(java.lang.String autocomplete)
           Set the value of the autocomplete property.
 void setAutoForm(boolean autoForm)
          Flag to indicate if this form has been auto created by the View.
 void setDir(java.lang.String dir)
          Set the value of the dir property.
 void setDojoAttributes(java.util.List<DojoAttribute> dojoAttributes)
           Set the value of the dojoAttributes property.
 void setDojoType(java.lang.String dojoType)
           Set the value of the dojoType property.
 void setEnctype(java.lang.String enctype)
           Set the value of the enctype property.
 void setNestedForm(boolean nestedForm)
          Flag to indicate whether or not a form is a nested form.
 void setParent(javax.faces.component.UIComponent parent)
           
 
Methods inherited from class javax.faces.component.UIForm
getFamily, isSubmitted, processDecodes, processUpdates, processValidators, setSubmitted
 
Methods inherited from class javax.faces.component.UIComponentBase
_xspCleanTransientData, _xspGetReadOnlyObj, _xspGetRendererData, _xspRemoveReadOnlyObj, _xspRemoveRendererData, _xspSetIdUnchecked, _xspSetReadOnlyObj, _xspSetRendererData, addFacesListener, broadcast, decode, encodeBegin, encodeChildren, encodeEnd, findComponent, getAttributes, getChildCount, getChildren, getClientId, getFacesContext, getFacesListeners, getFacet, getFacetCount, getFacets, getFacetsAndChildren, getId, getParent, getRenderer, getRendererType, getRendersChildren, getValueBinding, isRendered, isTransient, processRestoreState, processSaveState, queueEvent, removeFacesListener, restoreAttachedState, saveAttachedState, setId, setRendered, setRendererType, setTransient, setValueBinding
 
Methods inherited from class javax.faces.component.UIComponent
_xspGetStateId, _xspGetStateMap, _xspRestoreAttribute, _xspRestoreState, _xspSaveState, invokeOnComponent, isVisitable, markInitialState, setControlState, visitTree
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

COMPONENT_TYPE

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

RENDERER_TYPE

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

UIFormEx

public UIFormEx()
Create a new XFForm instance with default property values.

Method Detail

getStyleKitFamily

public java.lang.String getStyleKitFamily()
Description copied from interface: ThemeControl
The styleKitFamily is basically the default themeId, to use if the "themeId" property is not set on this control instance in the XPage source. For example, "InputField.EditBox" is used for most Edit Box controls. See Domino/xsp/nsf/themes/webstandard.theme for more examples.

The implementation may return different values depending on the configuration of the current control, for example the Button control returns a different value and looks different when it is configured as a cancel button.

Specified by:
getStyleKitFamily in interface ThemeControl
Returns:
a non-null themeId corresponding to the configuration for this type of control in a theme file.

isNestedForm

public boolean isNestedForm()
Defaults to false, this should be set to nestedForm="true" when the XPage designer wants to create a form that is nested within another HTML form. By default nested forms cause an error to prevent the page from displaying, as they are usually indicative of a problem, but when this is set to true the error is avoided and the nested form is allowed.

Returns:
true if a form is a nested form.

setNestedForm

public void setNestedForm(boolean nestedForm)
Flag to indicate whether or not a form is a nested form.

Parameters:
nestedForm - true if the form is a nested form

isAutoForm

public boolean isAutoForm()
Indicates if this form has been auto created by the View. Not a property set in the All Properties tab, this is determined by the XPage root control.

Returns:
true if it has been auto created.

setAutoForm

public void setAutoForm(boolean autoForm)
Flag to indicate if this form has been auto created by the View.

Parameters:
autoForm - true if this has been automatically created

getDir

public java.lang.String getDir()

Return the value of the dir property. Contents:

Direction indication for text that does not inherit directionality. Valid values are "LTR" (left-to-right) and "RTL" (right-to-left).


setDir

public void setDir(java.lang.String dir)

Set the value of the dir property.


getAutocomplete

public java.lang.String getAutocomplete()

Return the value of the autocomplete property. Contents:

Disables the browser automatically complete feature for this control when set to "off"


setAutocomplete

public void setAutocomplete(java.lang.String autocomplete)

Set the value of the autocomplete property.


getDojoType

public java.lang.String getDojoType()

Return the value of the dojoType property. Contents:

Sets the default Dojo Type used to create this control in the browser.

Also, see the "dojoForm" property.

Specified by:
getDojoType in interface FacesDojoComponent
See Also:
UIViewRootEx.isDojoForm()

setDojoType

public void setDojoType(java.lang.String dojoType)

Set the value of the dojoType property.


getDojoAttributes

public java.util.List<DojoAttribute> getDojoAttributes()

Return the value of the dojoAttributes property. Contents:

A list of Dojo attributes

Specified by:
getDojoAttributes in interface FacesDojoComponent

addDojoAttribute

public void addDojoAttribute(DojoAttribute attribute)
Add a dojo attribute to the set associated with this property.

Parameters:
action -

setDojoAttributes

public void setDojoAttributes(java.util.List<DojoAttribute> dojoAttributes)

Set the value of the dojoAttributes property.


setParent

public void setParent(javax.faces.component.UIComponent parent)
Overrides:
setParent in class javax.faces.component.UIComponentBase

save

public void save()
          throws javax.faces.FacesException
Calling this method will cause all data sources contained within this form to have their contents saved and also have the associated data model removed from the associated bean manager.

Throws:
javax.faces.FacesException

save

public void save(boolean removeFromManager)
          throws javax.faces.FacesException
Calling this method will cause all data sources contained within this form to have their contents saved and optionally have the associated data model removed from the associated bean manager.

Throws:
javax.faces.FacesException

saveState

public java.lang.Object saveState(javax.faces.context.FacesContext context)
Specified by:
saveState in interface javax.faces.component.StateHolder
Overrides:
saveState in class javax.faces.component.UIComponentBase

restoreState

public void restoreState(javax.faces.context.FacesContext context,
                         java.lang.Object state)
Specified by:
restoreState in interface javax.faces.component.StateHolder
Overrides:
restoreState in class javax.faces.component.UIComponentBase

getEnctype

public java.lang.String getEnctype()

Return the value of the enctype property. Contents:

Content type used to submit the form to the server. If not specified, the default value is "multipart/form-data".


setEnctype

public void setEnctype(java.lang.String enctype)

Set the value of the enctype property.