|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.hippoecm.hst.component.support.forms.FormUtils
public class FormUtils
Field Summary | |
---|---|
static String |
DEFAULT_FORMDATA_CONTAINER
|
static String |
DEFAULT_FORMDATA_TYPE
|
static String |
DEFAULT_STORED_FORMS_LOCATION
|
static String |
DEFAULT_UUID_NAME
|
static String |
HST_CREATIONTIME
|
static String |
HST_FORM_DATA_NODE
|
static String |
HST_FORM_FIELD_DATA
|
static String |
HST_FORM_FIELD_MESSAGES
|
static String |
HST_FORM_FIELD_NAME
|
static String |
HST_PREDECESSOR
|
static String |
HST_SEALED
|
Constructor Summary | |
---|---|
FormUtils()
|
Method Summary | |
---|---|
static FormMap |
getFormMap(javax.servlet.http.HttpServletRequest request)
Returns a populated FormaMap for some form data node if that node can be found with the u_u_i_d parameter on the request . |
static javax.jcr.Session |
getWritableSession()
|
static void |
persistFormMap(HstRequest request,
HstResponse response,
FormMap formMap,
StoreFormResult storeFormResult)
Facility to temporarily store submitted form data which needs to be accessed in the rendering phase again. |
static void |
populate(HstRequest request,
FormMap formMap)
This method tries to repopulate an earlier posted form that was stored in the repository. |
static void |
populate(javax.servlet.http.HttpServletRequest request,
FormMap formMap)
This method tries to repopulate an earlier posted form that was stored in the repository. |
static void |
validateId(String uuid)
Validates an uuid. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final String DEFAULT_UUID_NAME
public static final String DEFAULT_STORED_FORMS_LOCATION
public static final String DEFAULT_FORMDATA_CONTAINER
public static final String DEFAULT_FORMDATA_TYPE
public static final String HST_CREATIONTIME
public static final String HST_PREDECESSOR
public static final String HST_FORM_DATA_NODE
public static final String HST_FORM_FIELD_DATA
public static final String HST_FORM_FIELD_MESSAGES
public static final String HST_FORM_FIELD_NAME
public static final String HST_SEALED
Constructor Detail |
---|
public FormUtils()
Method Detail |
---|
public static FormMap getFormMap(javax.servlet.http.HttpServletRequest request)
request
. If no such form data node can be found, an empty FormMap
will be returned
request
- the HttpServletRequest
FormMap
for the formdata node belonging to the UUID from request parameter u_u_i_d
If there is no formdata for the UUID or no u_u_i_d parameter, just an empty FormMap
object will be returned#populate(javax.servlet.http.HttpServletRequest, FormMap)}
public static void populate(javax.servlet.http.HttpServletRequest request, FormMap formMap)
request
- the HttpServletRequest
formMap
- a not yet populated FormMap object (just new FormMap())public static void populate(HstRequest request, FormMap formMap)
request
- the current hstRequestformMap
- the formMap that will be populatedrather use {@link #populate(javax.servlet.http.HttpServletRequest, FormMap)} instead
of this method
public static void persistFormMap(HstRequest request, HstResponse response, FormMap formMap, StoreFormResult storeFormResult) throws HstComponentException
request
- the requestresponse
- the responseformMap
- the form names + values to temporarily storestoreFormResult
- an object to store some result of the data persisting, for example the uuid of the created node
HstComponentException
- when the storing of the formdata failspublic static void validateId(String uuid) throws IllegalArgumentException
uuid
- uuid to validate
IllegalArgumentException
- thrown on invalid uuidpublic static javax.jcr.Session getWritableSession() throws javax.jcr.RepositoryException
javax.jcr.RepositoryException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |