HDIV API 2.0.4

org.hdiv.components
Class FormHDIV

java.lang.Object
  extended by org.apache.struts2.components.Component
      extended by org.apache.struts2.components.UIBean
          extended by org.apache.struts2.components.ClosingUIBean
              extended by org.apache.struts2.components.Form
                  extended by org.hdiv.components.FormHDIV

public class FormHDIV
extends org.apache.struts2.components.Form

Renders HTML an input form.

The remote form allows the form to be submitted without the page being refreshed. The results from the form can be inserted into any HTML element on the page.

NOTE:

The order / logic in determining the posting url of the generated HTML form is as follows:-

  1. If the action attribute is not specified, then the current request will be used to determine the posting url
  2. If the action is given, Struts will try to obtain an ActionConfig. This will be successfull if the action attribute is a valid action alias defined struts.xml.
  3. If the action is given and is not an action alias defined in struts.xml, Struts will used the action attribute as if it is the posting url, separting the namespace from it and using UrlHelper to generate the final url.

Examples

  <!-- START SNIPPET: example -->
  <p/>
  <s:form ... />
  <p/>
  <!-- END SNIPPET: example -->
 

Since:
HDIV 2.0
Author:
Gorka Vicente

Field Summary
static java.lang.String OPEN_TEMPLATE
           
static java.lang.String TEMPLATE
           
 
Fields inherited from class org.apache.struts2.components.Form
acceptcharset, action, configuration, enableDynamicMethodInvocation, enctype, method, namespace, objectFactory, onsubmit, portletMode, target, validate, windowState
 
Fields inherited from class org.apache.struts2.components.UIBean
accesskey, cssClass, cssStyle, defaultTemplateDir, defaultUITheme, disabled, key, label, labelPosition, name, onblur, onchange, onclick, ondblclick, onfocus, onkeydown, onkeypress, onkeyup, onmousedown, onmousemove, onmouseout, onmouseover, onmouseup, onselect, request, required, requiredposition, response, tabindex, template, templateDir, templateEngineManager, templateSuffix, theme, title, tooltip, tooltipConfig, value
 
Fields inherited from class org.apache.struts2.components.Component
actionMapper, COMPONENT_STACK, id, parameters, stack
 
Constructor Summary
FormHDIV(com.opensymphony.xwork2.util.ValueStack stack, javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
           
 
Method Summary
protected  void addHDIVParameter(java.util.Map hdivParameters)
          Adds HDIV state as a parameter.
 boolean end(java.io.Writer writer, java.lang.String body)
           
 org.hdiv.dataComposer.IDataComposer getDataComposer()
           
 java.lang.String getDefaultOpenTemplate()
           
protected  java.lang.String getDefaultTemplate()
           
 
Methods inherited from class org.apache.struts2.components.Form
evaluateExtraParams, evaluateNameValue, getSequence, getValidators, populateComponentHtmlId, setAcceptcharset, setAction, setConfiguration, setEnableDynamicMethodInvocation, setEnctype, setMethod, setNamespace, setObjectFactory, setOnsubmit, setPortletMode, setTarget, setValidate, setWindowState
 
Methods inherited from class org.apache.struts2.components.ClosingUIBean
setOpenTemplate, start
 
Methods inherited from class org.apache.struts2.components.UIBean
addFormParameter, buildTemplateName, enableAncestorFormCustomOnsubmit, escape, evaluateParams, getTemplate, getTemplateDir, getTheme, getTooltipConfig, getValueClassType, mergeTemplate, setAccesskey, setCssClass, setCssStyle, setDefaultTemplateDir, setDefaultUITheme, setDisabled, setKey, setLabel, setLabelposition, setName, setOnblur, setOnchange, setOnclick, setOndblclick, setOnfocus, setOnkeydown, setOnkeypress, setOnkeyup, setOnmousedown, setOnmousemove, setOnmouseout, setOnmouseover, setOnmouseup, setOnselect, setRequired, setRequiredposition, setTabindex, setTemplate, setTemplateDir, setTemplateEngineManager, setTheme, setTitle, setTooltip, setTooltipConfig, setValue
 
Methods inherited from class org.apache.struts2.components.Component
addAllParameters, addParameter, altSyntax, copyParams, determineActionURL, determineNamespace, end, fieldError, findAncestor, findString, findString, findValue, findValue, findValue, getComponentStack, getId, getParameters, getStack, popComponentStack, setActionMapper, setId, toString, usesBody
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

OPEN_TEMPLATE

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

TEMPLATE

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

FormHDIV

public FormHDIV(com.opensymphony.xwork2.util.ValueStack stack,
                javax.servlet.http.HttpServletRequest request,
                javax.servlet.http.HttpServletResponse response)
Method Detail

getDefaultOpenTemplate

public java.lang.String getDefaultOpenTemplate()
Overrides:
getDefaultOpenTemplate in class org.apache.struts2.components.Form

getDefaultTemplate

protected java.lang.String getDefaultTemplate()
Overrides:
getDefaultTemplate in class org.apache.struts2.components.Form

getDataComposer

public org.hdiv.dataComposer.IDataComposer getDataComposer()
Returns:
Returns data composer from request

end

public boolean end(java.io.Writer writer,
                   java.lang.String body)
Overrides:
end in class org.apache.struts2.components.UIBean

addHDIVParameter

protected void addHDIVParameter(java.util.Map hdivParameters)
Adds HDIV state as a parameter.

Parameters:
hdivParameters -

HDIV 2.0.4

Copyright © 2008 hdiv.org. All Rights Reserved.