org.mmbase.bridge.jsp.taglib.typehandler
Class BinaryHandler

java.lang.Object
  extended byorg.mmbase.bridge.jsp.taglib.typehandler.AbstractTypeHandler
      extended byorg.mmbase.bridge.jsp.taglib.typehandler.BinaryHandler
All Implemented Interfaces:
TypeHandler
Direct Known Subclasses:
ByteHandler

public class BinaryHandler
extends AbstractTypeHandler

Since:
MMBase-1.8 (was named ByteHandler previously)
Version:
$Id: BinaryHandler.java,v 1.4 2006/07/06 15:02:40 michiel Exp $
Author:
Gerard van de Looi, Michiel Meeuwissen
Warning: No Java Documentation Available.

Field Summary
 
Fields inherited from class org.mmbase.bridge.jsp.taglib.typehandler.AbstractTypeHandler
eh, gotEnumHandler, tag
 
Constructor Summary
BinaryHandler(FieldInfoTag tag)
          Constructor
 
Method Summary
 String checkHtmlInput(Node node, Field field, boolean errors)
          Produces a div, containing the error message for the current value, or the empty string if everything ok.
protected  Object getFieldValue(Field field)
          Returns the field value as specified by the client's post.
 String htmlInput(Node node, Field field, boolean search)
          Produces an form input field for the given Node, and Field.
protected  void setValue(Node node, Field field, org.apache.commons.fileupload.FileItem bytes)
          Sets the binary value.
 boolean useHtmlInput(Node node, Field field)
          returns true if setValue happened.
 String whereHtmlInput(Field field)
           
 
Methods inherited from class org.mmbase.bridge.jsp.taglib.typehandler.AbstractTypeHandler
addExtraAttributes, cast, findString, getClasses, getEnumHandler, getFieldValue, getOperator, getSearchValue, init, interpretEmptyAsNull, paramHtmlInput, prefix, prefixError, prefixID, whereHtmlInput
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BinaryHandler

public BinaryHandler(FieldInfoTag tag)
Constructor

Parameters:
tag -
Method Detail

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)

getFieldValue

protected Object getFieldValue(Field field)
                        throws JspTagException
Returns the field value as specified by the client's post.

Overrides:
getFieldValue in class AbstractTypeHandler
Throws:
JspTagException

checkHtmlInput

public String checkHtmlInput(Node node,
                             Field field,
                             boolean errors)
                      throws JspTagException
Description copied from interface: TypeHandler
Produces a div, containing the error message for the current value, or the empty string if everything ok.

Specified by:
checkHtmlInput in interface TypeHandler
Overrides:
checkHtmlInput in class AbstractTypeHandler
Throws:
JspTagException

setValue

protected void setValue(Node node,
                        Field field,
                        org.apache.commons.fileupload.FileItem bytes)
                 throws JspTagException
Sets the binary value. Also tries to set some fields which are generaly associated with the binary. This could actually be moved to commit-processors of those fields.

Throws:
JspTagException

useHtmlInput

public boolean useHtmlInput(Node node,
                            Field field)
                     throws JspTagException
Description copied from interface: TypeHandler
returns true if setValue happened.

Specified by:
useHtmlInput in interface TypeHandler
Overrides:
useHtmlInput in class AbstractTypeHandler
Throws:
JspTagException
See Also:
TypeHandler.useHtmlInput(Node, Field)

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)


MMBase build 1.8.1.20060716