org.opensubsystems.patterns.ordereddata.www
Class OrderedDataButtonsTag

java.lang.Object
  extended by javax.servlet.jsp.tagext.TagSupport
      extended by javax.servlet.jsp.tagext.BodyTagSupport
          extended by org.opensubsystems.core.www.PageElementCacheTag
              extended by org.opensubsystems.core.www.BlockElementTag
                  extended by org.opensubsystems.patterns.ordereddata.www.OrderedDataButtonsTag
All Implemented Interfaces:
java.io.Serializable, javax.servlet.jsp.tagext.BodyTag, javax.servlet.jsp.tagext.IterationTag, javax.servlet.jsp.tagext.JspTag, javax.servlet.jsp.tagext.Tag

public class OrderedDataButtonsTag
extends org.opensubsystems.core.www.BlockElementTag

Custom tag to generate buttons allowing to ordering data items in a table.

Version:
$Id: OrderedDataButtonsTag.java,v 1.9 2007/01/07 06:14:53 bastafidli Exp $
Author:
Julian Legeny
See Also:
Serialized Form
Code reviewer:
Miro Halas
Code reviewed:
1.4 2006/04/29 00:26:35 jlegeny

Field Summary
protected  java.lang.String m_strComputedOrder
          Flag which will configures if an artificial order number will be computed when item is reordered.
protected  java.lang.String m_strDisabled
          If the controls generated by this tag should be disabled then this attribute should say true or 1.
protected  java.lang.String m_strOrderedItems
          Values specifying mapping between ids of data objects managed by the controls and artificial order number specifying order of those data objects, The format for order is following: ID1:ORDER_NUMBER1;ID2:ORDER_NUMBER2;...;IDn:ORDER_NUMBERn
protected  java.lang.String m_strPrefix
          Prefix used for all html fields generated by this tag.
 
Fields inherited from class org.opensubsystems.core.www.BlockElementTag
CURRENT_ELEMENT_ID, DIV_BLOCK_ELEMENT, m_strCssclass, m_strIdSuffix, m_strRelatedIds, m_strStyle, m_strType, SPAN_BLOCK_ELEMENT
 
Fields inherited from class org.opensubsystems.core.www.PageElementCacheTag
CACHE_INDICATOR, CSS_ELEMENT, JS_ELEMENT, m_strCacheas, m_strId, PAGE_ELEMENTS_CACHE, SCRIPT_ELEMENT
 
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
OrderedDataButtonsTag()
          Constructor for custom tag.
 
Method Summary
 int doEndTag()
          
 int doStartTag()
          
 java.lang.String getComputeorder()
           
 java.lang.String getDisabled()
           
 java.lang.String getOrdereditems()
           
 java.lang.String getPrefix()
           
 boolean isComputedOrder()
           
 boolean isDisabledButtons()
           
 void setComputeorder(boolean bComputedOrder)
           
 void setComputeorder(java.lang.String strComputedOrder)
           
 void setDisabled(boolean bDisabled)
           
 void setDisabled(java.lang.String strDisabled)
           
 void setOrdereditems(java.lang.String strOrderedItems)
           
 void setPrefix(java.lang.String strPrefix)
           
 
Methods inherited from class org.opensubsystems.core.www.BlockElementTag
adjustId, getCssclass, getCurrentId, getRelatedids, getStyle, getType, isRelatedIdsTag, popCurrentId, pushCurrentId, restoreId, setCssclass, setRelatedids, setRelatedids, setStoredId, setStyle, setType
 
Methods inherited from class org.opensubsystems.core.www.PageElementCacheTag
cache, getCacheas, getCachedContent, getCachedContent, getCachedContent, getCachedContentElements, getId, setCacheas, setId
 
Methods inherited from class javax.servlet.jsp.tagext.BodyTagSupport
doAfterBody, doInitBody, getBodyContent, getPreviousOut, release, setBodyContent
 
Methods inherited from class javax.servlet.jsp.tagext.TagSupport
findAncestorWithClass, getParent, getValue, getValues, removeValue, setPageContext, setParent, 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, setParent
 

Field Detail

m_strPrefix

protected java.lang.String m_strPrefix
Prefix used for all html fields generated by this tag.


m_strDisabled

protected java.lang.String m_strDisabled
If the controls generated by this tag should be disabled then this attribute should say true or 1.


m_strOrderedItems

protected java.lang.String m_strOrderedItems
Values specifying mapping between ids of data objects managed by the controls and artificial order number specifying order of those data objects, The format for order is following: ID1:ORDER_NUMBER1;ID2:ORDER_NUMBER2;...;IDn:ORDER_NUMBERn


m_strComputedOrder

protected java.lang.String m_strComputedOrder
Flag which will configures if an artificial order number will be computed when item is reordered. If the order should be computed for reordered item this should say true or 1. If this is false or 0 then then item will be just moved on the gui without computing new order value. Default value is true.

Constructor Detail

OrderedDataButtonsTag

public OrderedDataButtonsTag()
Constructor for custom tag.

Method Detail

doStartTag

public int doStartTag()
               throws javax.servlet.jsp.JspException

Specified by:
doStartTag in interface javax.servlet.jsp.tagext.Tag
Overrides:
doStartTag in class org.opensubsystems.core.www.BlockElementTag
Throws:
javax.servlet.jsp.JspException

doEndTag

public int doEndTag()
             throws javax.servlet.jsp.JspException

Specified by:
doEndTag in interface javax.servlet.jsp.tagext.Tag
Overrides:
doEndTag in class org.opensubsystems.core.www.BlockElementTag
Throws:
javax.servlet.jsp.JspException

getPrefix

public java.lang.String getPrefix()
Returns:
String - prefix used for all html fields generated by this tag.

setPrefix

public void setPrefix(java.lang.String strPrefix)
Parameters:
strPrefix - - prefix used for all html fields generated by this tag.

getDisabled

public java.lang.String getDisabled()
Returns:
String - If the controls generated by this tag should be disabled then this attribute should say true or 1.

setDisabled

public void setDisabled(java.lang.String strDisabled)
Parameters:
strDisabled - - If the controls generated by this tag should be disabled then this attribute should say true or 1.

setDisabled

public void setDisabled(boolean bDisabled)
Parameters:
bDisabled - - If this button should be disabled then this attribute should say true or 1.

isDisabledButtons

public boolean isDisabledButtons()
Returns:
boolean - true if this button should be disabled

getOrdereditems

public java.lang.String getOrdereditems()
Returns:
- ordered items value

setOrdereditems

public void setOrdereditems(java.lang.String strOrderedItems)
Parameters:
strOrderedItems - - new ordered items value

getComputeorder

public java.lang.String getComputeorder()
Returns:
String - If the order should be computed for reordered item this should say true or 1. If this is false or 0 then then item will be just moved on the gui without computing new order value.

setComputeorder

public void setComputeorder(java.lang.String strComputedOrder)
Parameters:
strComputedOrder - - If the order should be computed for reordered item this should say true or 1. If this is false or 0 then then item will be just moved on the gui without computing new order value.

setComputeorder

public void setComputeorder(boolean bComputedOrder)
Parameters:
bComputedOrder - - If the order should be computed should say true or 1.

isComputedOrder

public boolean isComputedOrder()
Returns:
boolean - true if the order has to be computed


Copyright © 2003 - 2006 OpenSubsystems s.r.o.