站内搜索: 请输入搜索关键词
当前页面: 在线文档首页 > JBOSS Portal 2.6 API 英文版文档

Converter - JBOSS Portal 2.6 API 英文版文档


org.jboss.portal.common.value
Interface Converter


public interface Converter

Version:
$Revision: 5451 $
Author:
Julien Viet

Method Summary
 boolean accept(java.lang.Class clazz)
          Return true if the converter accepts the class for conversion.
 java.lang.Object toObject(java.lang.String value)
          String to object conversion.
 java.lang.String toString(java.lang.Object value)
          Convert the object to the stored value.
 

Method Detail

accept

public boolean accept(java.lang.Class clazz)
Return true if the converter accepts the class for conversion.

Throws:
java.lang.IllegalArgumentException - if the class object is null

toObject

public java.lang.Object toObject(java.lang.String value)
                          throws NullConversionException,
                                 FormatConversionException
String to object conversion.

Throws:
NullConversionException - if the value nullity prevent the conversion
FormatConversionException - if the value cannot be converted

toString

public java.lang.String toString(java.lang.Object value)
                          throws NullConversionException,
                                 FormatConversionException
Convert the object to the stored value.

Throws:
NullConversionException - if the value nullity prevent the conversion
FormatConversionException - if the value cannot be converted