org.mmbase.bridge.jsp.taglib.typehandler
Class EnumHandler
java.lang.Object
org.mmbase.bridge.jsp.taglib.typehandler.AbstractTypeHandler
org.mmbase.bridge.jsp.taglib.typehandler.EnumHandler
- All Implemented Interfaces:
- TypeHandler
- Direct Known Subclasses:
- BooleanHandler
- public class EnumHandler
- extends AbstractTypeHandler
- implements TypeHandler
This handler can be used to create option list by use of a resource.
- Since:
- MMBase-1.6
- Version:
- $Id: EnumHandler.java,v 1.38 2006/06/06 17:47:43 michiel Exp $
- Author:
- Michiel Meeuwissen
|
Method Summary |
protected Object |
cast(Object value,
Node node,
Field field)
|
protected EnumHandler |
getEnumHandler(Node node,
Field field)
|
protected Object |
getFieldValue(Node node,
Field field,
boolean useDefault)
Returns the field value to be used in the page. |
protected Iterator |
getIterator(Node node,
Field field)
|
String |
htmlInput(Node node,
Field field,
boolean search)
Produces an form input field for the given Node, and Field. |
boolean |
isAvailable()
|
void |
paramHtmlInput(ParamHandler handler,
Field field)
|
String |
whereHtmlInput(Field field)
|
Constraint |
whereHtmlInput(Field field,
Query query)
Adds search constraint to Query object. |
| Methods inherited from class org.mmbase.bridge.jsp.taglib.typehandler.AbstractTypeHandler |
addExtraAttributes, checkHtmlInput, findString, getClasses, getFieldValue, getOperator, getSearchValue, init, interpretEmptyAsNull, prefix, prefixError, prefixID, useHtmlInput |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
EnumHandler
public EnumHandler(FieldInfoTag tag)
throws JspTagException
- Since:
- MMBase-1.8
EnumHandler
public EnumHandler(FieldInfoTag tag,
Node node,
Field field)
throws JspTagException
- Parameters:
tag - - Since:
- MMBase-1.8
getIterator
protected Iterator getIterator(Node node,
Field field)
throws JspTagException
- Throws:
JspTagException- Since:
- MMBase-1.8
getEnumHandler
protected EnumHandler getEnumHandler(Node node,
Field field)
throws JspTagException
- Overrides:
getEnumHandler in class AbstractTypeHandler
- Throws:
JspTagException
isAvailable
public boolean isAvailable()
cast
protected Object cast(Object value,
Node node,
Field field)
- Overrides:
cast in class AbstractTypeHandler
getFieldValue
protected Object getFieldValue(Node node,
Field field,
boolean useDefault)
throws JspTagException
- Description copied from class:
AbstractTypeHandler
- Returns the field value to be used in the page.
- Overrides:
getFieldValue in class AbstractTypeHandler
- Throws:
JspTagException
htmlInput
public String htmlInput(Node node,
Field field,
boolean search)
throws JspTagException
- Description copied from interface:
TypeHandler
- Produces an form input field for the given Node, and Field.
- Specified by:
htmlInput in interface TypeHandler- Overrides:
htmlInput in class AbstractTypeHandler
- Throws:
JspTagException- See Also:
TypeHandler.htmlInput(Node, Field, boolean)
paramHtmlInput
public void paramHtmlInput(ParamHandler handler,
Field field)
throws JspTagException
- Specified by:
paramHtmlInput in interface TypeHandler- Overrides:
paramHtmlInput in class AbstractTypeHandler
- Throws:
JspTagException
whereHtmlInput
public String whereHtmlInput(Field field)
throws JspTagException
- Specified by:
whereHtmlInput in interface TypeHandler- Overrides:
whereHtmlInput in class AbstractTypeHandler
- Throws:
JspTagException- See Also:
TypeHandler.whereHtmlInput(Field)
whereHtmlInput
public Constraint whereHtmlInput(Field field,
Query query)
throws JspTagException
- Description copied from class:
AbstractTypeHandler
- Adds search constraint to Query object.
- Specified by:
whereHtmlInput in interface TypeHandler- Overrides:
whereHtmlInput in class AbstractTypeHandler
- Returns:
- null if nothing to be searched, the constraint if constraint added
- Throws:
JspTagException
MMBase build 1.8.1.20060716