Package jadex.commons.transformation
Interface IStringConverter
- 
- All Known Implementing Classes:
- JadexBasicTypeSerializer,- JadexJsonSerializer
 
 public interface IStringConverterConvert to and from a string.
- 
- 
Field SummaryFields Modifier and Type Field Description static java.lang.StringTYPE_BASICstatic java.lang.StringTYPE_JSONstatic java.lang.StringTYPE_XML
 - 
Method SummaryAll Methods Instance Methods Abstract Methods Modifier and Type Method Description java.lang.StringconvertObject(java.lang.Object val, java.lang.Class<?> type, java.lang.ClassLoader cl, java.lang.Object context)Convert an object to a string.java.lang.ObjectconvertString(java.lang.String val, java.lang.Class<?> type, java.lang.ClassLoader cl, java.lang.Object context)Convert a string to an object.java.lang.StringgetType()Get the type of string that can be processed (xml, json, plain).booleanisSupportedType(java.lang.Class<?> clazz)Test if the type can be converted.
 
- 
- 
- 
Field Detail- 
TYPE_BASICstatic final java.lang.String TYPE_BASIC - See Also:
- Constant Field Values
 
 - 
TYPE_JSONstatic final java.lang.String TYPE_JSON - See Also:
- Constant Field Values
 
 - 
TYPE_XMLstatic final java.lang.String TYPE_XML - See Also:
- Constant Field Values
 
 
- 
 - 
Method Detail- 
convertStringjava.lang.Object convertString(java.lang.String val, java.lang.Class<?> type, java.lang.ClassLoader cl, java.lang.Object context)Convert a string to an object.- Parameters:
- val- The string.
- type- The target type.
- context- The context.
- Returns:
- The object.
 
 - 
convertObjectjava.lang.String convertObject(java.lang.Object val, java.lang.Class<?> type, java.lang.ClassLoader cl, java.lang.Object context)Convert an object to a string.- Parameters:
- val- The object.
- type- The encoding type.
- context- The context.
- Returns:
- The object.
 
 - 
getTypejava.lang.String getType() Get the type of string that can be processed (xml, json, plain).- Returns:
- The object.
 
 - 
isSupportedTypeboolean isSupportedType(java.lang.Class<?> clazz) Test if the type can be converted.- Parameters:
- clazz- The class.
- Returns:
- True if can be converted.
 
 
- 
 
-