com.filenet.wcm.apps.server.ui.info
Class WcmSelectPropertiesPage

java.lang.Object
  extended bycom.filenet.wcm.toolkit.server.base.WcmDpContainer
      extended bycom.filenet.wcm.toolkit.server.base.WcmModule
          extended bycom.filenet.wcm.toolkit.server.base.GlobalEventModule
              extended bycom.filenet.wcm.toolkit.server.base.WcmUiModule
                  extended bycom.filenet.wcm.toolkit.server.ui.WcmXSLModule
                      extended bycom.filenet.wcm.apps.server.ui.info.WcmSelectPropertiesPage
All Implemented Interfaces:
com.filenet.wcm.toolkit.server.base.WcmModuleInterface, com.filenet.wcm.toolkit.server.base.WcmPanelInterface, com.filenet.wcm.toolkit.server.base.WcmPanelValidationInterface, com.filenet.wcm.toolkit.server.base.WcmUiModuleInterface, com.filenet.wcm.toolkit.server.base.WcmViewPanelInterface

public class WcmSelectPropertiesPage
extends com.filenet.wcm.toolkit.server.ui.WcmXSLModule
implements com.filenet.wcm.toolkit.server.base.WcmViewPanelInterface, com.filenet.wcm.toolkit.server.base.WcmPanelValidationInterface

This class handles output of properties in a number of different scenarios. It works in conjunction with WcmPropertiesInfoPage.xsl and the properties xml returned from the Authoring Data Provider or, in some cases, the xml created here for new objects. This class makes great use of WcmPropertiesUtil.

See Also:
WcmPropertiesUtil

Field Summary
protected  java.lang.String propCacheKey
           
 
Fields inherited from class com.filenet.wcm.toolkit.server.ui.WcmXSLModule
transformUtil
 
Fields inherited from class com.filenet.wcm.toolkit.server.base.WcmModule
NAME_DELIMITER
 
Constructor Summary
protected WcmSelectPropertiesPage()
          protected Constructor sets the default type, the name and creates the WcmPropertiesUtil object.
  WcmSelectPropertiesPage(int type)
          Constructor sets the Property type to one of the static int values defined above.
 
Method Summary
 void cleanup()
          Cleanup module properties
 java.lang.String getFormName()
          Overridden to return the form name used so wizard navigation will submit it.
protected  org.w3c.dom.Document getOutputXML()
          Gets the Document interface on the properties XML
protected  org.w3c.dom.Document getPropertiesXML()
          Gets the Document interface on the properties XML.
 java.util.Iterator getValidationErrors()
          Unused.
 void initialize()
          Initializes data providers, XSL parameters, the authoring state and other state values.
 boolean isApplyButtonRequired()
          Tells the Info page if it should put up an Apply button.
 boolean isModified()
          Indicates that the state has changed as a result of a wizardSave call.
 void onChangePage(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Used by links to redirect to secondary property pages after it submits the form by calling onSubmit.
 void onCollapse(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Handle Collapse on expanded object property
 void onExpand(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Handle Expand on object Property
 void onGetInfo(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
           
 void onSelectObject(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Handle Select Object event.
 void onSelectSystemProperties(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
           
 void onSetObject(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
           
 void onStartPage(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Set XSL parameters and other setup before showing the property page.
 void onSubmit(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          This event updates the output XML from the request data.
 void panelFinish(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Calls setProperties on the object.
 void panelInitClientProperties(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Called only when in App Integration/Client mode.
 void panelSave(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Calls onSubmit
 boolean panelValidate()
          Validates the properties
 void removeSingleProperty()
          Provides the mechanism for removing a single property value.
 void render(java.io.Writer w)
          Renders the properties.
 void reset()
          Resets data provider and module properties.
 void setFormName(java.lang.String formName)
          Sets the form name string
 void setReadOnly(boolean bReadOnly)
          Pass true to set this property page as read only.
 void showSingleProperty(java.lang.String propertySymname)
          Used for Intermediate Select Object page that provides the remove Object assignment link.
 
Methods inherited from class com.filenet.wcm.toolkit.server.ui.WcmXSLModule
convertToNodeList, getXML, getXSLParameter, renderXSL, setXML, setXML, setXML, setXML, setXSL, setXSLParameter, setXSLParameter, setXSLParameter, setXSLParameter, setXSLParameter, setXSLParameter
 
Methods inherited from class com.filenet.wcm.toolkit.server.base.WcmUiModule
getActive, getBasePath, getBaseUrl, getBaseURLBuilder, getControllerEventUrl, getControllerEventUrl, getEventFormFields, getEventFormFields, getEventFormTag, getEventFormTag, getEventUrl, getEventUrl, getEventUrl, getEventUrl, getFormSubmitUrl, getFormSubmitUrl, getGlobalEventUrl, getGlobalEventUrl, getPageUrl, getPageUrl, getPageUrl, getPageUrl, getUiParent, peekEvent, renderJSP, routeEvent, routeEvent, serverSideInclude, serverSideInclude, setActive, setJSP
 
Methods inherited from class com.filenet.wcm.toolkit.server.base.GlobalEventModule
subscribeGlobalEvent
 
Methods inherited from class com.filenet.wcm.toolkit.server.base.WcmModule
addChild, addChild, addChild, debugTrace, getClassProperty, getClassProperty, getClassPropertyKeys, getConfiguration, getController, getDataStore, getModuleProperty, getModuleProperty, getModuleProperty, getModuleProperty, getModulePropertyKeys, getName, getParent, getWindowProperty, getWindowProperty, persist, queryDataProvider, setClassProperty, setClassProperty, setController, setModuleProperty, setModuleProperty, setName, setParent, setPortletParent, setWindowProperty
 
Methods inherited from class com.filenet.wcm.toolkit.server.base.WcmDpContainer
addDataProvider, addDataProvider
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.filenet.wcm.toolkit.server.base.WcmModuleInterface
addDataProvider, getDataStore, getModuleProperty, getName, getParent, persist, queryDataProvider, setController, setModuleProperty, setName, setParent
 

Field Detail

propCacheKey

protected java.lang.String propCacheKey
Constructor Detail

WcmSelectPropertiesPage

protected WcmSelectPropertiesPage()
                           throws java.lang.Exception
protected Constructor sets the default type, the name and creates the WcmPropertiesUtil object. Used internally.

Throws:
java.lang.Exception

WcmSelectPropertiesPage

public WcmSelectPropertiesPage(int type)
                        throws java.lang.Exception
Constructor sets the Property type to one of the static int values defined above.

Parameters:
type - One of the defined int field types.
Throws:
java.lang.Exception
Method Detail

initialize

public void initialize()
                throws java.lang.Exception
Initializes data providers, XSL parameters, the authoring state and other state values.

Specified by:
initialize in interface com.filenet.wcm.toolkit.server.base.WcmModuleInterface
Throws:
java.lang.Exception

onCollapse

public void onCollapse(javax.servlet.http.HttpServletRequest request,
                       javax.servlet.http.HttpServletResponse response)
                throws java.lang.Exception
Handle Collapse on expanded object property

Parameters:
request - The request Object
response - The response Object
Throws:
java.lang.Exception

onExpand

public void onExpand(javax.servlet.http.HttpServletRequest request,
                     javax.servlet.http.HttpServletResponse response)
              throws java.lang.Exception
Handle Expand on object Property

Parameters:
request - The request Object
response - The response Object
Throws:
java.lang.Exception

onSelectObject

public void onSelectObject(javax.servlet.http.HttpServletRequest request,
                           javax.servlet.http.HttpServletResponse response)
                    throws java.lang.Exception
Handle Select Object event. Redirects to the Select Object operation page for selecting a value for an object valued property.

Parameters:
request - The request Object
response - The response Object
Throws:
java.lang.Exception

onSetObject

public void onSetObject(javax.servlet.http.HttpServletRequest request,
                        javax.servlet.http.HttpServletResponse response)
                 throws java.lang.Exception
Throws:
java.lang.Exception

onStartPage

public void onStartPage(javax.servlet.http.HttpServletRequest request,
                        javax.servlet.http.HttpServletResponse response)
                 throws java.lang.Exception
Set XSL parameters and other setup before showing the property page.

Specified by:
onStartPage in interface com.filenet.wcm.toolkit.server.base.WcmUiModuleInterface
Parameters:
request - HttpServletRequest object
response - HttpServletResponse object
Throws:
java.lang.Exception

setReadOnly

public void setReadOnly(boolean bReadOnly)
                 throws java.lang.Exception
Pass true to set this property page as read only.

Parameters:
bReadOnly - Value desired for read only.
Throws:
java.lang.Exception

showSingleProperty

public void showSingleProperty(java.lang.String propertySymname)
                        throws java.lang.Exception
Used for Intermediate Select Object page that provides the remove Object assignment link. This will cause the property page to show only the indicated property.

Parameters:
propertySymname - The symbolic name of the property to show.
Throws:
java.lang.Exception

removeSingleProperty

public void removeSingleProperty()
                          throws java.lang.Exception
Provides the mechanism for removing a single property value.

Throws:
java.lang.Exception

render

public void render(java.io.Writer w)
            throws java.lang.Exception
Renders the properties.

Specified by:
render in interface com.filenet.wcm.toolkit.server.base.WcmUiModuleInterface
Parameters:
w - Writer object to write to.
Throws:
java.lang.Exception

getPropertiesXML

protected org.w3c.dom.Document getPropertiesXML()
                                         throws java.lang.Exception
Gets the Document interface on the properties XML. Also sets the class property for the output XML.

Returns:
The property descriptions xml.
Throws:
java.lang.Exception

getOutputXML

protected org.w3c.dom.Document getOutputXML()
                                     throws java.lang.Exception
Gets the Document interface on the properties XML

Returns:
The output xml.
Throws:
java.lang.Exception

getFormName

public java.lang.String getFormName()
Overridden to return the form name used so wizard navigation will submit it.

Specified by:
getFormName in interface com.filenet.wcm.toolkit.server.base.WcmUiModuleInterface
Returns:
Returns the form name.

setFormName

public void setFormName(java.lang.String formName)
Sets the form name string

Parameters:
formName - String

onGetInfo

public void onGetInfo(javax.servlet.http.HttpServletRequest request,
                      javax.servlet.http.HttpServletResponse response)
               throws java.lang.Exception
Throws:
java.lang.Exception

onChangePage

public void onChangePage(javax.servlet.http.HttpServletRequest request,
                         javax.servlet.http.HttpServletResponse response)
                  throws java.lang.Exception
Used by links to redirect to secondary property pages after it submits the form by calling onSubmit.

Parameters:
request - HttpServletRequest object
response - HttpServletResponse object
Throws:
java.lang.Exception

onSubmit

public void onSubmit(javax.servlet.http.HttpServletRequest request,
                     javax.servlet.http.HttpServletResponse response)
              throws java.lang.Exception
This event updates the output XML from the request data.

Parameters:
request - HttpServletRequest object
response - HttpServletResponse object
Throws:
java.lang.Exception

panelInitClientProperties

public void panelInitClientProperties(javax.servlet.http.HttpServletRequest request,
                                      javax.servlet.http.HttpServletResponse response)
                               throws java.lang.Exception
Called only when in App Integration/Client mode. Initializes the properties page with any propertiesXml parameters that are provided as property values.

Parameters:
request - HttpServletRequest object
response - HttpServletResponse object
Throws:
java.lang.Exception

panelSave

public void panelSave(javax.servlet.http.HttpServletRequest request,
                      javax.servlet.http.HttpServletResponse response)
               throws java.lang.Exception
Calls onSubmit

Specified by:
panelSave in interface com.filenet.wcm.toolkit.server.base.WcmPanelInterface
Parameters:
request - HttpServletRequest object
response - HttpServletResponse object
Throws:
java.lang.Exception

panelValidate

public boolean panelValidate()
                      throws java.lang.Exception
Validates the properties

Specified by:
panelValidate in interface com.filenet.wcm.toolkit.server.base.WcmPanelValidationInterface
Returns:
true if no exception is thrown
Throws:
java.lang.Exception

getValidationErrors

public java.util.Iterator getValidationErrors()
Unused.

Specified by:
getValidationErrors in interface com.filenet.wcm.toolkit.server.base.WcmPanelValidationInterface
Returns:
null

panelFinish

public void panelFinish(javax.servlet.http.HttpServletRequest request,
                        javax.servlet.http.HttpServletResponse response)
                 throws java.lang.Exception
Calls setProperties on the object.

Specified by:
panelFinish in interface com.filenet.wcm.toolkit.server.base.WcmPanelInterface
Parameters:
request - HttpServletRequest object
response - HttpServletResponse object
Throws:
java.lang.Exception

cleanup

public void cleanup()
             throws java.lang.Exception
Cleanup module properties

Specified by:
cleanup in interface com.filenet.wcm.toolkit.server.base.WcmModuleInterface
Throws:
java.lang.Exception

reset

public void reset()
           throws java.lang.Exception
Resets data provider and module properties.

Throws:
java.lang.Exception

isModified

public boolean isModified()
                   throws java.lang.Exception
Indicates that the state has changed as a result of a wizardSave call.

Specified by:
isModified in interface com.filenet.wcm.toolkit.server.base.WcmViewPanelInterface
Returns:
true if page's state has changed.
Throws:
java.lang.Exception

isApplyButtonRequired

public boolean isApplyButtonRequired()
                              throws java.lang.Exception
Tells the Info page if it should put up an Apply button.

Specified by:
isApplyButtonRequired in interface com.filenet.wcm.toolkit.server.base.WcmViewPanelInterface
Returns:
true.
Throws:
java.lang.Exception

onSelectSystemProperties

public void onSelectSystemProperties(javax.servlet.http.HttpServletRequest request,
                                     javax.servlet.http.HttpServletResponse response)
                              throws java.lang.Exception
Throws:
java.lang.Exception


© Copyright IBM Corp. 2002, 2007. All Rights Reserved.