|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.fudgemsg.types.StringFieldTypeConverter
public class StringFieldTypeConverter
Converts any object values to a string using the object's toString method.
Field Summary | |
---|---|
static StringFieldTypeConverter |
INSTANCE
Singleton instance of the converter. |
Method Summary | |
---|---|
boolean |
canConvertPrimary(Class<? extends Object> clazz)
Always returns true . |
String |
primaryToSecondary(Object object)
Returns toString called on the object. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static StringFieldTypeConverter INSTANCE
Method Detail |
---|
public boolean canConvertPrimary(Class<? extends Object> clazz)
true
. Any object has a toString
method.
canConvertPrimary
in interface FudgeTypeConverter<Object,String>
clazz
- to query
true
if a call to FudgeTypeConverter.primaryToSecondary(Primary)
will succeed, false
if it would failpublic String primaryToSecondary(Object object)
toString
called on the object.
primaryToSecondary
in interface FudgeTypeConverter<Object,String>
object
- to convert
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |