com.raritantechnologies.searchApp.taglibrary
Class ObjectDisplayForm

java.lang.Object
  extended byBodyTagSupport
      extended bycom.raritantechnologies.searchApp.taglibrary.ObjectDisplayForm
All Implemented Interfaces:
IConfigurable, ICustomTag

public class ObjectDisplayForm
extends BodyTagSupport
implements ICustomTag, IConfigurable

Displays information from any object. Used to display data from any type of collection.

ObjectDisplayForm is selected using the JSP tag <results:ObjectDisplayForm > defined in DisplayForm.tld.

JSP Custom Tag Template:
  <results:ObjectDisplayForm formName="[ name of display form in configuration XML (see below ) ]"
                          resultFormName="[ additional Form using the object results ]"
                          pageSize="[ number of records per page ]" />
 
XML Configuration Template:
  <ObjectDisplayForm name="formName" 
              rendererClass="com.raritantechnologies.someRendererClass"
              bgcolor1="#ffffff" bgcolor2="#dddddd" >

   <!-- details needed by someRendererClass -->

  </ObjectDisplayForm>
 

Developed by Raritan Technologies .

Author:
Pat Crabtree
See Also:
Serialized Form

Field Summary
protected  java.lang.String pageNumParam
           
protected  int pageSize
           
 
Constructor Summary
ObjectDisplayForm()
           
 
Method Summary
 int doAfterBody()
           
 int doStartTag()
           
 java.lang.String getBody(RaritanPageContext rpc)
          Renders the results display form given a search request encoded within the RaritanPageContext.
static java.util.ArrayList getCachedObjectSet(RaritanPageContext rPageContext, java.lang.String cacheKey, java.lang.String formType)
           
 java.lang.String getObjectFormName()
           
 java.util.ArrayList getObjectList(int pageNum, int pageSize, RaritanPageContext pageContext)
           
static IObjectDisplayFormRenderer getObjectRenderer(java.util.Map sessionData, java.lang.String objectFormName, java.lang.String objectDisplayFormClass)
           
static IObjectDisplayFormRenderer getObjectRenderer(RaritanPageContext rpc, java.lang.String objectFormName)
           
static java.util.Map getSessionData(RaritanPageContext pageContext)
           
 void initialize(org.w3c.dom.Element elem)
          This initialize method is used when the DisplayForm is contained in a wrapper object such as a TabbedCustomTag - and is an alternate way of initiating a DisplayForm from the JSP custom tag initialization via the java bean methods.
 void initialize(java.util.Map initParams)
           
protected  void setCachedObjectSet(RaritanPageContext rPageContext, java.lang.String localKey, java.util.ArrayList objectSet)
           
 void setObjectDisplayFormClass(java.lang.String objectDisplayFormClass)
           
 void setObjectFormName(java.lang.String objectFormName)
           
 void setObjectSetKey(java.lang.String objectSetKey)
           
 java.util.ArrayList updateCollection(java.lang.String userName, java.util.ArrayList lastObjectSet)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

pageSize

protected int pageSize

pageNumParam

protected java.lang.String pageNumParam
Constructor Detail

ObjectDisplayForm

public ObjectDisplayForm()
Method Detail

initialize

public void initialize(org.w3c.dom.Element elem)
This initialize method is used when the DisplayForm is contained in a wrapper object such as a TabbedCustomTag - and is an alternate way of initiating a DisplayForm from the JSP custom tag initialization via the java bean methods. Note that the main configuration Display form Renderer initialization is handled separately - i.e. this is NOT the initialization for the DisplayForm tags in the main configuration XML. Those tags configure the IDisplayFormRenderer used by this DisplayForm object.

Specified by:
initialize in interface IConfigurable

initialize

public void initialize(java.util.Map initParams)
Specified by:
initialize in interface ICustomTag

doStartTag

public int doStartTag()
               throws JspException
Throws:
JspException

getBody

public java.lang.String getBody(RaritanPageContext rpc)
Renders the results display form given a search request encoded within the RaritanPageContext. Key input parameters:

Specified by:
getBody in interface ICustomTag
Parameters:
rpc - Platform-neutral page context ( can be used in non J2EE environments such as ASP).
Returns:
The tag body text string.

getObjectList

public java.util.ArrayList getObjectList(int pageNum,
                                         int pageSize,
                                         RaritanPageContext pageContext)

updateCollection

public java.util.ArrayList updateCollection(java.lang.String userName,
                                            java.util.ArrayList lastObjectSet)

getCachedObjectSet

public static java.util.ArrayList getCachedObjectSet(RaritanPageContext rPageContext,
                                                     java.lang.String cacheKey,
                                                     java.lang.String formType)

getSessionData

public static java.util.Map getSessionData(RaritanPageContext pageContext)

setCachedObjectSet

protected void setCachedObjectSet(RaritanPageContext rPageContext,
                                  java.lang.String localKey,
                                  java.util.ArrayList objectSet)

doAfterBody

public int doAfterBody()
                throws JspException
Throws:
JspException

getObjectRenderer

public static IObjectDisplayFormRenderer getObjectRenderer(RaritanPageContext rpc,
                                                           java.lang.String objectFormName)

getObjectRenderer

public static IObjectDisplayFormRenderer getObjectRenderer(java.util.Map sessionData,
                                                           java.lang.String objectFormName,
                                                           java.lang.String objectDisplayFormClass)

getObjectFormName

public java.lang.String getObjectFormName()

setObjectFormName

public void setObjectFormName(java.lang.String objectFormName)

setObjectDisplayFormClass

public void setObjectDisplayFormClass(java.lang.String objectDisplayFormClass)

setObjectSetKey

public void setObjectSetKey(java.lang.String objectSetKey)