org.dbforms.taglib
Class EmbeddedData

java.lang.Object
  extended by javax.servlet.jsp.tagext.TagSupport
      extended by javax.servlet.jsp.tagext.BodyTagSupport
          extended by org.dbforms.taglib.TagSupportWithScriptHandler
              extended by org.dbforms.taglib.DbBaseHandlerTag
                  extended by org.dbforms.taglib.EmbeddedData
All Implemented Interfaces:
Serializable, javax.servlet.jsp.tagext.BodyTag, javax.servlet.jsp.tagext.IterationTag, javax.servlet.jsp.tagext.Tag, javax.servlet.jsp.tagext.TryCatchFinally, StaticDataAddInterface
Direct Known Subclasses:
ConfTableData, QueryData, TableData

public abstract class EmbeddedData
extends DbBaseHandlerTag
implements javax.servlet.jsp.tagext.TryCatchFinally, StaticDataAddInterface

DOCUMENT ME!

Version:
$Revision: 1.38 $
Author:
$author$
See Also:
Serialized Form

Field Summary
 
Fields inherited from class javax.servlet.jsp.tagext.BodyTagSupport
bodyContent
 
Fields inherited from class javax.servlet.jsp.tagext.TagSupport
id, pageContext
 
Fields inherited from interface javax.servlet.jsp.tagext.BodyTag
EVAL_BODY_BUFFERED, EVAL_BODY_TAG
 
Fields inherited from interface javax.servlet.jsp.tagext.IterationTag
EVAL_BODY_AGAIN
 
Fields inherited from interface javax.servlet.jsp.tagext.Tag
EVAL_BODY_INCLUDE, EVAL_PAGE, SKIP_BODY, SKIP_PAGE
 
Constructor Summary
EmbeddedData()
           
 
Method Summary
 void addElement(KeyValuePair pair)
          DOCUMENT ME!
 void doCatch(Throwable t)
           
 void doFinally()
          DOCUMENT ME!
 int doStartTag()
          DOCUMENT ME!
protected abstract  List fetchData(Connection con)
          this method is implemented by subclasses in order to match the user's need for specific data.
protected  List formatEmbeddedResultRows(ResultSetVector rsv)
          formatEmbeddedResultRows() formats a result set accornding to a eventually given format string.
 String getDbConnectionName()
          DOCUMENT ME!
 String getDisableCache()
          Insert the method's description here.
 IEscaper getEscaper()
          DOCUMENT ME!
 String getFormatClass()
          Returns the formatClass.
 String getName()
          returns the unique name of the embedded data
 void setDbConnectionName(String name)
          DOCUMENT ME!
 void setDisableCache(String newDisableCache)
          Insert the method's description here.
 void setFormat(String format)
          DOCUMENT ME!
 void setFormatClass(String formatClass)
          Sets the formatClass.
 void setName(String name)
          set the name of the embedded data. every embedded data entity on a jsp page has to have a unique name. this name is used for storing (caching) and retrieving data in Page-Scope. this is useful if a tag gets evaluated many times -> we do not want the queries etc. to be executed every time!
protected  boolean useCache()
          DOCUMENT ME!
 
Methods inherited from class org.dbforms.taglib.DbBaseHandlerTag
customFormat, escapeHTML, getCustomFormatter, getDefaultValue, getEscaperClass, getField, getFieldObject, getFieldValue, getFormattedFieldValue, getFormatter, getFormFieldDefaultValue, getFormFieldName, getFormFieldValue, getLocale, getMaxlength, getOverrideFormFieldName, getParentForm, getPattern, getReadOnlyStyleClass, getStyleClass, hasOverrideFormFieldNameSet, hasReadOnlySet, renderOldValueHtmlInputField, renderPatternHtmlInputField, setCustomFormatter, setDefaultValue, setEscaperClass, setField, setFieldName, setMaxlength, setNullFieldValue, setOverrideFormFieldName, setParent, setPattern, setReadOnly, setReadOnlyStyleClass, typicalDefaultValue, writeOutSpecialValues
 
Methods inherited from class org.dbforms.taglib.TagSupportWithScriptHandler
getAccessKey, getConfig, getOnBlur, getOnChange, getOnClick, getOnDblClick, getOnFocus, getOnKeyDown, getOnKeyPress, getOnKeyUp, getOnMouseDown, getOnMouseMove, getOnMouseOut, getOnMouseOver, getOnMouseUp, getOnSelect, getStyle, getTabIndex, getTitle, prepareEventHandlers, prepareStyles, setAccessKey, setOnBlur, setOnChange, setOnClick, setOnDblClick, setOnFocus, setOnKeyDown, setOnKeyPress, setOnKeyUp, setOnMouseDown, setOnMouseMove, setOnMouseOut, setOnMouseOver, setOnMouseUp, setOnSelect, setStyle, setStyleClass, setTabIndex, setTitle
 
Methods inherited from class javax.servlet.jsp.tagext.BodyTagSupport
doAfterBody, doEndTag, doInitBody, getBodyContent, getPreviousOut, release, setBodyContent
 
Methods inherited from class javax.servlet.jsp.tagext.TagSupport
findAncestorWithClass, getId, getParent, getValue, getValues, removeValue, setId, setPageContext, setValue
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface javax.servlet.jsp.tagext.Tag
getParent, setPageContext
 

Constructor Detail

EmbeddedData

public EmbeddedData()
Method Detail

setDbConnectionName

public void setDbConnectionName(String name)
DOCUMENT ME!

Parameters:
name - DOCUMENT ME!

getDbConnectionName

public String getDbConnectionName()
DOCUMENT ME!

Returns:
DOCUMENT ME!

setDisableCache

public void setDisableCache(String newDisableCache)
Insert the method's description here. Creation date: (2001-09-21 12:20:42)

Parameters:
newDisableCache - java.lang.String

getDisableCache

public String getDisableCache()
Insert the method's description here. Creation date: (2001-09-21 12:20:42)

Returns:
java.lang.String

getEscaper

public IEscaper getEscaper()
DOCUMENT ME!

Overrides:
getEscaper in class DbBaseHandlerTag
Returns:
DOCUMENT ME!

setFormat

public void setFormat(String format)
DOCUMENT ME!

Parameters:
format - DOCUMENT ME!

setFormatClass

public void setFormatClass(String formatClass)
Sets the formatClass.

Parameters:
formatClass - The formatClass to set

getFormatClass

public String getFormatClass()
Returns the formatClass.

Returns:
String

setName

public void setName(String name)
set the name of the embedded data. every embedded data entity on a jsp page has to have a unique name. this name is used for storing (caching) and retrieving data in Page-Scope. this is useful if a tag gets evaluated many times -> we do not want the queries etc. to be executed every time!

Parameters:
name - DOCUMENT ME!

getName

public String getName()
returns the unique name of the embedded data

Overrides:
getName in class DbBaseHandlerTag
Returns:
DOCUMENT ME!

addElement

public void addElement(KeyValuePair pair)
DOCUMENT ME!

Specified by:
addElement in interface StaticDataAddInterface
Parameters:
pair - DOCUMENT ME!

doCatch

public void doCatch(Throwable t)
             throws Throwable
Specified by:
doCatch in interface javax.servlet.jsp.tagext.TryCatchFinally
Throws:
Throwable
See Also:
TryCatchFinally.doCatch(java.lang.Throwable)

doFinally

public void doFinally()
DOCUMENT ME!

Specified by:
doFinally in interface javax.servlet.jsp.tagext.TryCatchFinally
Overrides:
doFinally in class DbBaseHandlerTag
See Also:
TryCatchFinally.doFinally()

doStartTag

public int doStartTag()
               throws javax.servlet.jsp.JspException
DOCUMENT ME!

Specified by:
doStartTag in interface javax.servlet.jsp.tagext.Tag
Overrides:
doStartTag in class javax.servlet.jsp.tagext.BodyTagSupport
Returns:
DOCUMENT ME!
Throws:
javax.servlet.jsp.JspException - DOCUMENT ME!
IllegalArgumentException - DOCUMENT ME!

fetchData

protected abstract List fetchData(Connection con)
                           throws SQLException
this method is implemented by subclasses in order to match the user's need for specific data.

Parameters:
con - DOCUMENT ME!
Returns:
DOCUMENT ME!
Throws:
SQLException

formatEmbeddedResultRows

protected List formatEmbeddedResultRows(ResultSetVector rsv)
formatEmbeddedResultRows() formats a result set accornding to a eventually given format string. If no format string is given, the output format is a comma separated list of values. This method is called by subclasses TableData and QueryData

Parameters:
rsv - result set vector to be formatted
Returns:
a vector of key-value pairs, the values eventually formatted according to a given format string

useCache

protected boolean useCache()
DOCUMENT ME!

Returns:
DOCUMENT ME!


Copyright © 2002-2005 DbForms. All Rights Reserved.