org.makumba.forms.tags
Class MatchModeTag
java.lang.Object
javax.servlet.jsp.tagext.TagSupport
org.makumba.analyser.AnalysableElement
org.makumba.analyser.AnalysableTag
org.makumba.commons.tags.GenericMakumbaTag
org.makumba.forms.tags.MatchModeTag
- All Implemented Interfaces:
- Serializable, IterationTag, JspTag, Tag
public class MatchModeTag
- extends GenericMakumbaTag
Implements a match mode chooser, which can take the form of a select box or a radio button, and allows to select the
type of match mode for the enclosing search criterion. Different modes apply for string (char, text), number (int,
real) and date types. The latter two can also be matched against a range.
- Version:
- $Id: MatchModeTag.java,v 1.1 Oct 21, 2007 1:37:25 PM rudi Exp $
- Author:
- Rudolf Mayer
- See Also:
- Serialized Form
Methods inherited from class org.makumba.commons.tags.GenericMakumbaTag |
doAnalyzedCleanup, doStartTag, getParams, initialiseState, isAttribute, setAddTitle, setCols, setElementSeparator, setEllipsis, setEllipsisLength, setEmpty, setFormat, setHtml, setLabelSeparator, setLineSeparator, setLongLineLength, setMaxlength, setMaxLength, setOnClick, setOnDblClick, setOnKeyDown, setOnKeyPress, setOnKeyUp, setOnMouseDown, setOnMouseMove, setOnMouseOut, setOnMouseOver, setOnMouseUp, setRows, setSize, setStyle, setStyleClass, setStyleId, setTitle, setType, setUrlEncode, toString |
Methods inherited from class org.makumba.analyser.AnalysableTag |
addTagText, canHaveBody, checkAttributeValues, doAnalyzedStartTag, doEndAnalyze, doEndTag, getElementData, getPageContext, getPageTextInfo, getTagKey, getTagText, needPageCache, notEmpty, onlyInt, registerAttributeValues, setTagDataAtAnalysis |
Methods inherited from class org.makumba.analyser.AnalysableElement |
checkTagFound, discardJSPParsingData, getAnalyzedElementData, getCurrentBodyTagData, getElementAfter, getElementBefore, getPageCache, getPageCache, getRunningElementData, getTagByAttribute, getTagById, getThreadElementStack, initializeThread, keepAnalysisState, setAnalyzedElementData, setRunningElementData |
Methods inherited from class javax.servlet.jsp.tagext.TagSupport |
doAfterBody, findAncestorWithClass, getId, getParent, getValue, getValues, release, removeValue, setId, setPageContext, setParent, setValue |
allowedTypes
public static final String[] allowedTypes
knownRangeMatchModes
public static final Hashtable<String,String> knownRangeMatchModes
-
knownStringMatchModes
public static final Hashtable<String,String> knownStringMatchModes
knownDateMatchModes
public static final Hashtable<String,String> knownDateMatchModes
knownNumberMatchModes
public static final Hashtable<String,String> knownNumberMatchModes
allMatchModes
public static final Hashtable<String,String> allMatchModes
MatchModeTag
public MatchModeTag()
getValidMatchmodes
public static Hashtable<String,String> getValidMatchmodes(boolean isRange,
FieldDefinition fd)
setMatchModes
public void setMatchModes(String s)
setType
public void setType(String s)
- Overrides:
setType
in class GenericMakumbaTag
doStartAnalyze
public void doStartAnalyze(PageCache pageCache)
- Description copied from class:
AnalysableTag
- Starts the analysis of the tag, without knowing what tags follow it in the page. Typically this method will
allocate initial data structures, that are then completed at doEndAnalyze()
- Overrides:
doStartAnalyze
in class AnalysableTag
- Parameters:
pageCache
- The page cache for the current page
getCriterionTag
protected CriterionTag getCriterionTag()
doAnalyzedEndTag
public int doAnalyzedEndTag(PageCache pageCache)
throws LogicException,
JspException
- Description copied from class:
AnalysableTag
- makumba-specific endTag
- Overrides:
doAnalyzedEndTag
in class AnalysableTag
- Parameters:
pageCache
- The page cache for the current page
- Throws:
LogicException
JspException
- See Also:
AnalysableTag.doEndTag()
setTagKey
public void setTagKey(PageCache pageCache)
- Description copied from class:
AnalysableTag
- Sets tagKey to uniquely identify this tag. Called at analysis time before doStartAnalyze() and at runtime before
doMakumbaStartTag()
- Overrides:
setTagKey
in class AnalysableTag
- Parameters:
pageCache
- The page cache for the current page- See Also:
AnalysableTag.doAnalyzedStartTag(org.makumba.analyser.PageCache)
,
AnalysableTag.doStartAnalyze(org.makumba.analyser.PageCache)
registerPossibleAttributeValues
protected void registerPossibleAttributeValues()
- Description copied from class:
AnalysableTag
- Override this in order to register possible attribute values using
AnalysableTag.registerAttributeValues(String, String...)
. The registered attributes are checked before
AnalysableTag.doStartAnalyze(PageCache)
and throw a ProgrammerError
is thrown if the provided value is not
allowed.
- Overrides:
registerPossibleAttributeValues
in class AnalysableTag
allowsIdenticalKey
public boolean allowsIdenticalKey()
- Description copied from class:
AnalysableTag
- Determines whether the tag can have the same key as others in the page
- Overrides:
allowsIdenticalKey
in class AnalysableTag
- Returns:
true
if the tag is allowed to have the same key as others in the page, false
otherwise
setDefault
public void setDefault(String s)
- Overrides:
setDefault
in class GenericMakumbaTag