- All Implemented Interfaces:
Converter<String,
,Object> Decoder<String,
,Object> Encoder<Object,
,String> JoinableEncoder<Object,
,String> JoinablePrimitiveEncoder<String>
,ObjectConverter<String>
,PrimitiveDecoder<String>
,PrimitiveEncoder<String>
,SplittableDecoder<String,
,Object> SplittablePrimitiveDecoder<String>
- Direct Known Subclasses:
ParameterConverter
An extensible string converter.
This converter is backed by a StringConverter
which can convert
primitive and common objects, it can be extended to be able to convert other
types of objects by injecting specific compound decoders and encoders.
This converter is an object converter and as such it can convert collection of objects using a customizable separator.
- Since:
- 1.0
- Author:
- Jeremy Kuhn
- See Also:
-
Constructor Summary
ConstructorDescriptionCreates a string composite converter with the default array/list separator (StringConverter.DEFAULT_ARRAY_LIST_SEPARATOR
.StringCompositeConverter
(String arrayListSeparator) Creates a string composite converter with the specified array/list separator. -
Method Summary
Modifier and TypeMethodDescriptiondecodeBigDecimal
(String value) Decodes to big decimal.decodeBigInteger
(String value) Decodes to big integer.decodeBoolean
(String value) Decodes to boolean.decodeByte
(String value) Decodes to byte.decodeCharacter
(String value) Decodes to character.Class
<?> decodeClass
(String value) Decodes to class.decodeCurrency
(String value) Decodes to currency.decodeDouble
(String value) Decodes to double.decodeFile
(String value) Decodes to file.decodeFloat
(String value) Decodes to float.decodeInetAddress
(String value) Decodes to inet address.decodeInetSocketAddress
(String value) Decodes to inet socket address.decodeInteger
(String value) Decodes to integer.decodeLocalDate
(String value) Decodes to local date.decodeLocalDateTime
(String value) Decodes to local datetime.decodeLocale
(String value) Decodes to locale.decodeLong
(String value) Decodes to long.decodePath
(String value) Decodes to path.decodePattern
(String value) Decodes to pattern.decodeShort
(String value) Decodes to short.decodeString
(String value) Decodes to string.<T> T[]
decodeToArray
(String value, Class<T> type) Decodes the specified value whose type is represented by the specified class to an array of decoded values.<T> T[]
decodeToArray
(String value, Type type) Decodes the specified value whose type is the specified type to an array of decoded values.<T> List
<T> decodeToList
(String value, Class<T> type) Decodes the specified value whose type is represented by the specified class to a list of decoded values.<T> List
<T> decodeToList
(String value, Type type) Decodes the specified value whose type is the specified type to a list of decoded values.<T> Set
<T> decodeToSet
(String value, Class<T> type) Decodes the specified value whose type is represented by the specified class to a set of decoded values.<T> Set
<T> decodeToSet
(String value, Type type) Decodes the specified value whose type is the specified type to a set of decoded values.Decodes to URI.Decodes to URL.decodeZonedDateTime
(String value) Decodes to zoned datetime.Encodes file.Encodes boolean.Encodes byte.Encodes character.Encodes class.Encodes double.Encodes float.Encodes integer.Encodes long.Encodes short.Encodes string.encode
(BigDecimal value) Encodes big decimal.encode
(BigInteger value) Encodes big integer.encode
(InetAddress value) Encodes inet address.encode
(InetSocketAddress value) Encodes inet socket address.Encodes URI.Encodes URL.Encodes path.Encodes local date.encode
(LocalDateTime value) Encodes local datetime.encode
(ZonedDateTime value) Encodes zoned datetime.Encodes currency.Encodes locale.Encodes pattern.<T> String
encodeArray
(T[] value) Encodes the specified array of values to the encoded type.<T> String
encodeArray
(T[] value, Class<T> type) Encodes the specified array of values whose type is represented by the specified class to the encoded type.<T> String
encodeArray
(T[] value, Type type) Encodes the specified array of values whose type is represented by the specified class to the encoded type.<T> String
encodeList
(List<T> value) Encodes the specified list of values to an encoded value.<T> String
encodeList
(List<T> value, Class<T> type) Encodes the specified list of values whose type is represented by the specified class to an encoded value.<T> String
encodeList
(List<T> value, Type type) Encodes the specified list of values whose type is the specified type to an encoded value.<T> String
Encodes the specified set of values to an encoded value.<T> String
Encodes the specified set of values whose type is represented by the specified class to an encoded value.<T> String
Encodes the specified set of values whose type is the specified type to an encoded value.Returns the array/list separator used to convert lists and arrays.void
setArrayListSeparator
(String arrayListSeparator) Sets the array/list separator used to convert lists and arrays.void
setDecoders
(List<CompoundDecoder<String, ?>> decoders) Sets the compound decoders used to decode objects.void
setEncoders
(List<CompoundEncoder<?, String>> encoders) Sets the compound encoders used to encode objects.Methods inherited from class io.inverno.mod.base.converter.CompositeConverter
decode, decode, encode, encode, encode, setDefaultDecoder, setDefaultEncoder
-
Constructor Details
-
StringCompositeConverter
public StringCompositeConverter()Creates a string composite converter with the default array/list separator (
StringConverter.DEFAULT_ARRAY_LIST_SEPARATOR
. -
StringCompositeConverter
Creates a string composite converter with the specified array/list separator.
- Parameters:
arrayListSeparator
- an array/list separator
-
-
Method Details
-
getArrayListSeparator
Returns the array/list separator used to convert lists and arrays.
- Returns:
- an array/list separator
-
setArrayListSeparator
Sets the array/list separator used to convert lists and arrays.
- Parameters:
arrayListSeparator
- an array/list separator
-
setDecoders
Description copied from class:CompositeConverter
Sets the compound decoders used to decode objects.
- Overrides:
setDecoders
in classCompositeConverter<String>
- Parameters:
decoders
- a list of compound decoders
-
setEncoders
Description copied from class:CompositeConverter
Sets the compound encoders used to encode objects.
- Overrides:
setEncoders
in classCompositeConverter<String>
- Parameters:
encoders
- a list of compound encoders
-
decodeToList
Description copied from interface:SplittableDecoder
Decodes the specified value whose type is represented by the specified class to a list of decoded values.
- Specified by:
decodeToList
in interfaceSplittableDecoder<String,
Object> - Type Parameters:
T
- the type of the decoded object- Parameters:
value
- the value to decodetype
- the class of the decoded object- Returns:
- a list of decoded values
-
decodeToList
Description copied from interface:SplittableDecoder
Decodes the specified value whose type is the specified type to a list of decoded values.
- Specified by:
decodeToList
in interfaceSplittableDecoder<String,
Object> - Type Parameters:
T
- the type of the decoded object- Parameters:
value
- the value to decodetype
- the type of the decoded object- Returns:
- a list of decoded values
-
decodeToSet
Description copied from interface:SplittableDecoder
Decodes the specified value whose type is represented by the specified class to a set of decoded values.
- Specified by:
decodeToSet
in interfaceSplittableDecoder<String,
Object> - Type Parameters:
T
- the type of the decoded object- Parameters:
value
- the value to decodetype
- the class of the decoded object- Returns:
- a set of decoded values
-
decodeToSet
Description copied from interface:SplittableDecoder
Decodes the specified value whose type is the specified type to a set of decoded values.
- Specified by:
decodeToSet
in interfaceSplittableDecoder<String,
Object> - Type Parameters:
T
- the type of the decoded object- Parameters:
value
- the value to decodetype
- the type of the decoded object- Returns:
- a set of decoded values
-
decodeToArray
Description copied from interface:SplittableDecoder
Decodes the specified value whose type is represented by the specified class to an array of decoded values.
- Specified by:
decodeToArray
in interfaceSplittableDecoder<String,
Object> - Type Parameters:
T
- the type of the decoded object- Parameters:
value
- the value to decodetype
- the class of the decoded object- Returns:
- an array of decoded values
-
decodeToArray
Description copied from interface:SplittableDecoder
Decodes the specified value whose type is the specified type to an array of decoded values.
- Specified by:
decodeToArray
in interfaceSplittableDecoder<String,
Object> - Type Parameters:
T
- the type of the decoded object- Parameters:
value
- the value to decodetype
- the type of the decoded object- Returns:
- an array of decoded values
-
decodeByte
Description copied from interface:PrimitiveDecoder
Decodes to byte.
- Specified by:
decodeByte
in interfacePrimitiveDecoder<String>
- Parameters:
value
- the encoded value to decode- Returns:
- a decoded value
- Throws:
ConverterException
- if there was an error decoding the value
-
decodeShort
Description copied from interface:PrimitiveDecoder
Decodes to short.
- Specified by:
decodeShort
in interfacePrimitiveDecoder<String>
- Parameters:
value
- the encoded value to decode- Returns:
- a decoded value
- Throws:
ConverterException
- if there was an error decoding the value
-
decodeInteger
Description copied from interface:PrimitiveDecoder
Decodes to integer.
- Specified by:
decodeInteger
in interfacePrimitiveDecoder<String>
- Parameters:
value
- the encoded value to decode- Returns:
- a decoded value
- Throws:
ConverterException
- if there was an error decoding the value
-
decodeLong
Description copied from interface:PrimitiveDecoder
Decodes to long.
- Specified by:
decodeLong
in interfacePrimitiveDecoder<String>
- Parameters:
value
- the encoded value to decode- Returns:
- a decoded value
- Throws:
ConverterException
- if there was an error decoding the value
-
decodeFloat
Description copied from interface:PrimitiveDecoder
Decodes to float.
- Specified by:
decodeFloat
in interfacePrimitiveDecoder<String>
- Parameters:
value
- the encoded value to decode- Returns:
- a decoded value
- Throws:
ConverterException
- if there was an error decoding the value
-
decodeDouble
Description copied from interface:PrimitiveDecoder
Decodes to double.
- Specified by:
decodeDouble
in interfacePrimitiveDecoder<String>
- Parameters:
value
- the encoded value to decode- Returns:
- a decoded value
- Throws:
ConverterException
- if there was an error decoding the value
-
decodeCharacter
Description copied from interface:PrimitiveDecoder
Decodes to character.
- Specified by:
decodeCharacter
in interfacePrimitiveDecoder<String>
- Parameters:
value
- the encoded value to decode- Returns:
- a decoded value
- Throws:
ConverterException
- if there was an error decoding the value
-
decodeBoolean
Description copied from interface:PrimitiveDecoder
Decodes to boolean.
- Specified by:
decodeBoolean
in interfacePrimitiveDecoder<String>
- Parameters:
value
- the encoded value to decode- Returns:
- a decoded value
- Throws:
ConverterException
- if there was an error decoding the value
-
decodeString
Description copied from interface:PrimitiveDecoder
Decodes to string.
- Specified by:
decodeString
in interfacePrimitiveDecoder<String>
- Parameters:
value
- the encoded value to decode- Returns:
- a decoded value
- Throws:
ConverterException
- if there was an error decoding the value
-
decodeBigInteger
Description copied from interface:PrimitiveDecoder
Decodes to big integer.
- Specified by:
decodeBigInteger
in interfacePrimitiveDecoder<String>
- Parameters:
value
- the encoded value to decode- Returns:
- a decoded value
- Throws:
ConverterException
- if there was an error decoding the value
-
decodeBigDecimal
Description copied from interface:PrimitiveDecoder
Decodes to big decimal.
- Specified by:
decodeBigDecimal
in interfacePrimitiveDecoder<String>
- Parameters:
value
- the encoded value to decode- Returns:
- a decoded value
- Throws:
ConverterException
- if there was an error decoding the value
-
decodeLocalDate
Description copied from interface:PrimitiveDecoder
Decodes to local date.
- Specified by:
decodeLocalDate
in interfacePrimitiveDecoder<String>
- Parameters:
value
- the encoded value to decode- Returns:
- a decoded value
- Throws:
ConverterException
- if there was an error decoding the value
-
decodeLocalDateTime
Description copied from interface:PrimitiveDecoder
Decodes to local datetime.
- Specified by:
decodeLocalDateTime
in interfacePrimitiveDecoder<String>
- Parameters:
value
- the encoded value to decode- Returns:
- a decoded value
- Throws:
ConverterException
- if there was an error decoding the value
-
decodeZonedDateTime
Description copied from interface:PrimitiveDecoder
Decodes to zoned datetime.
- Specified by:
decodeZonedDateTime
in interfacePrimitiveDecoder<String>
- Parameters:
value
- the encoded value to decode- Returns:
- a decoded value
- Throws:
ConverterException
- if there was an error decoding the value
-
decodeCurrency
Description copied from interface:PrimitiveDecoder
Decodes to currency.
- Specified by:
decodeCurrency
in interfacePrimitiveDecoder<String>
- Parameters:
value
- the encoded value to decode- Returns:
- a decoded value
- Throws:
ConverterException
- if there was an error decoding the value
-
decodeLocale
Description copied from interface:PrimitiveDecoder
Decodes to locale.
- Specified by:
decodeLocale
in interfacePrimitiveDecoder<String>
- Parameters:
value
- the encoded value to decode- Returns:
- a decoded value
- Throws:
ConverterException
- if there was an error decoding the value
-
decodeFile
Description copied from interface:PrimitiveDecoder
Decodes to file.
- Specified by:
decodeFile
in interfacePrimitiveDecoder<String>
- Parameters:
value
- the encoded value to decode- Returns:
- a decoded value
- Throws:
ConverterException
- if there was an error decoding the value
-
decodePath
Description copied from interface:PrimitiveDecoder
Decodes to path.
- Specified by:
decodePath
in interfacePrimitiveDecoder<String>
- Parameters:
value
- the encoded value to decode- Returns:
- a decoded value
- Throws:
ConverterException
- if there was an error decoding the value
-
decodeURI
Description copied from interface:PrimitiveDecoder
Decodes to URI.
- Specified by:
decodeURI
in interfacePrimitiveDecoder<String>
- Parameters:
value
- the encoded value to decode- Returns:
- a decoded value
- Throws:
ConverterException
- if there was an error decoding the value
-
decodeURL
Description copied from interface:PrimitiveDecoder
Decodes to URL.
- Specified by:
decodeURL
in interfacePrimitiveDecoder<String>
- Parameters:
value
- the encoded value to decode- Returns:
- a decoded value
- Throws:
ConverterException
- if there was an error decoding the value
-
decodePattern
Description copied from interface:PrimitiveDecoder
Decodes to pattern.
- Specified by:
decodePattern
in interfacePrimitiveDecoder<String>
- Parameters:
value
- the encoded value to decode- Returns:
- a decoded value
- Throws:
ConverterException
- if there was an error decoding the value
-
decodeInetAddress
Description copied from interface:PrimitiveDecoder
Decodes to inet address.
- Specified by:
decodeInetAddress
in interfacePrimitiveDecoder<String>
- Parameters:
value
- the encoded value to decode- Returns:
- a decoded value
- Throws:
ConverterException
- if there was an error decoding the value
-
decodeInetSocketAddress
Description copied from interface:PrimitiveDecoder
Decodes to inet socket address.
- Specified by:
decodeInetSocketAddress
in interfacePrimitiveDecoder<String>
- Parameters:
value
- the encoded value to decode- Returns:
- a decoded value
- Throws:
ConverterException
- if there was an error decoding the value
-
decodeClass
Description copied from interface:PrimitiveDecoder
Decodes to class.
- Specified by:
decodeClass
in interfacePrimitiveDecoder<String>
- Parameters:
value
- the encoded value to decode- Returns:
- a decoded value
- Throws:
ConverterException
- if there was an error decoding the value
-
encodeList
Description copied from interface:JoinableEncoder
Encodes the specified list of values to an encoded value.
- Specified by:
encodeList
in interfaceJoinableEncoder<Object,
String> - Type Parameters:
T
- the type of the decoded object- Parameters:
value
- the list of objects to encode- Returns:
- an encoded value
-
encodeList
Description copied from interface:JoinableEncoder
Encodes the specified list of values whose type is represented by the specified class to an encoded value.
- Specified by:
encodeList
in interfaceJoinableEncoder<Object,
String> - Type Parameters:
T
- the type of the decoded object- Parameters:
value
- the list of objects to encodetype
- the class of the decoded object- Returns:
- an encoded value
-
encodeList
Description copied from interface:JoinableEncoder
Encodes the specified list of values whose type is the specified type to an encoded value.
- Specified by:
encodeList
in interfaceJoinableEncoder<Object,
String> - Type Parameters:
T
- the type of the decoded object- Parameters:
value
- the list of objects to encodetype
- the type of the decoded object- Returns:
- an encoded value
-
encodeSet
Description copied from interface:JoinableEncoder
Encodes the specified set of values to an encoded value.
- Specified by:
encodeSet
in interfaceJoinableEncoder<Object,
String> - Type Parameters:
T
- the type of the decoded object- Parameters:
value
- the set of objects to encode- Returns:
- an encoded value
-
encodeSet
Description copied from interface:JoinableEncoder
Encodes the specified set of values whose type is represented by the specified class to an encoded value.
- Specified by:
encodeSet
in interfaceJoinableEncoder<Object,
String> - Type Parameters:
T
- the type of the decoded object- Parameters:
value
- the set of objects to encodetype
- the class of the decoded object- Returns:
- an encoded value
-
encodeSet
Description copied from interface:JoinableEncoder
Encodes the specified set of values whose type is the specified type to an encoded value.
- Specified by:
encodeSet
in interfaceJoinableEncoder<Object,
String> - Type Parameters:
T
- the type of the decoded object- Parameters:
value
- the set of objects to encodetype
- the type of the decoded object- Returns:
- an encoded value
-
encodeArray
Description copied from interface:JoinableEncoder
Encodes the specified array of values to the encoded type.
- Specified by:
encodeArray
in interfaceJoinableEncoder<Object,
String> - Type Parameters:
T
- the type of the decoded object- Parameters:
value
- the array of objects to encode- Returns:
- an encoded value
-
encodeArray
Description copied from interface:JoinableEncoder
Encodes the specified array of values whose type is represented by the specified class to the encoded type.
- Specified by:
encodeArray
in interfaceJoinableEncoder<Object,
String> - Type Parameters:
T
- the type of the decoded object- Parameters:
value
- the array of objects to encodetype
- the class of the decoded object- Returns:
- an encoded value
-
encodeArray
Description copied from interface:JoinableEncoder
Encodes the specified array of values whose type is represented by the specified class to the encoded type.
- Specified by:
encodeArray
in interfaceJoinableEncoder<Object,
String> - Type Parameters:
T
- the type of the decoded object- Parameters:
value
- the array of objects to encodetype
- the class of the decoded object- Returns:
- an encoded value
-
encode
Description copied from interface:PrimitiveEncoder
Encodes byte.
- Specified by:
encode
in interfacePrimitiveEncoder<String>
- Parameters:
value
- the value to encode- Returns:
- an encoded value
- Throws:
ConverterException
- if there was an error encoding the value
-
encode
Description copied from interface:PrimitiveEncoder
Encodes short.
- Specified by:
encode
in interfacePrimitiveEncoder<String>
- Parameters:
value
- the value to encode- Returns:
- an encoded value
- Throws:
ConverterException
- if there was an error encoding the value
-
encode
Description copied from interface:PrimitiveEncoder
Encodes integer.
- Specified by:
encode
in interfacePrimitiveEncoder<String>
- Parameters:
value
- the value to encode- Returns:
- an encoded value
- Throws:
ConverterException
- if there was an error encoding the value
-
encode
Description copied from interface:PrimitiveEncoder
Encodes long.
- Specified by:
encode
in interfacePrimitiveEncoder<String>
- Parameters:
value
- the value to encode- Returns:
- an encoded value
- Throws:
ConverterException
- if there was an error encoding the value
-
encode
Description copied from interface:PrimitiveEncoder
Encodes float.
- Specified by:
encode
in interfacePrimitiveEncoder<String>
- Parameters:
value
- the value to encode- Returns:
- an encoded value
- Throws:
ConverterException
- if there was an error encoding the value
-
encode
Description copied from interface:PrimitiveEncoder
Encodes double.
- Specified by:
encode
in interfacePrimitiveEncoder<String>
- Parameters:
value
- the value to encode- Returns:
- an encoded value
- Throws:
ConverterException
- if there was an error encoding the value
-
encode
Description copied from interface:PrimitiveEncoder
Encodes character.
- Specified by:
encode
in interfacePrimitiveEncoder<String>
- Parameters:
value
- the value to encode- Returns:
- an encoded value
- Throws:
ConverterException
- if there was an error encoding the value
-
encode
Description copied from interface:PrimitiveEncoder
Encodes boolean.
- Specified by:
encode
in interfacePrimitiveEncoder<String>
- Parameters:
value
- the value to encode- Returns:
- an encoded value
- Throws:
ConverterException
- if there was an error encoding the value
-
encode
Description copied from interface:PrimitiveEncoder
Encodes string.
- Specified by:
encode
in interfacePrimitiveEncoder<String>
- Parameters:
value
- the value to encode- Returns:
- an encoded value
- Throws:
ConverterException
- if there was an error encoding the value
-
encode
Description copied from interface:PrimitiveEncoder
Encodes big integer.
- Specified by:
encode
in interfacePrimitiveEncoder<String>
- Parameters:
value
- the value to encode- Returns:
- an encoded value
- Throws:
ConverterException
- if there was an error encoding the value
-
encode
Description copied from interface:PrimitiveEncoder
Encodes big decimal.
- Specified by:
encode
in interfacePrimitiveEncoder<String>
- Parameters:
value
- the value to encode- Returns:
- an encoded value
- Throws:
ConverterException
- if there was an error encoding the value
-
encode
Description copied from interface:PrimitiveEncoder
Encodes local date.
- Specified by:
encode
in interfacePrimitiveEncoder<String>
- Parameters:
value
- the value to encode- Returns:
- an encoded value
- Throws:
ConverterException
- if there was an error encoding the value
-
encode
Description copied from interface:PrimitiveEncoder
Encodes local datetime.
- Specified by:
encode
in interfacePrimitiveEncoder<String>
- Parameters:
value
- the value to encode- Returns:
- an encoded value
- Throws:
ConverterException
- if there was an error encoding the value
-
encode
Description copied from interface:PrimitiveEncoder
Encodes zoned datetime.
- Specified by:
encode
in interfacePrimitiveEncoder<String>
- Parameters:
value
- the value to encode- Returns:
- an encoded value
- Throws:
ConverterException
- if there was an error encoding the value
-
encode
Description copied from interface:PrimitiveEncoder
Encodes currency.
- Specified by:
encode
in interfacePrimitiveEncoder<String>
- Parameters:
value
- the value to encode- Returns:
- an encoded value
- Throws:
ConverterException
- if there was an error encoding the value
-
encode
Description copied from interface:PrimitiveEncoder
Encodes locale.
- Specified by:
encode
in interfacePrimitiveEncoder<String>
- Parameters:
value
- the value to encode- Returns:
- an encoded value
- Throws:
ConverterException
- if there was an error encoding the value
-
encode
Description copied from interface:PrimitiveEncoder
Encodes file.
- Specified by:
encode
in interfacePrimitiveEncoder<String>
- Parameters:
value
- the value to encode- Returns:
- an encoded value
- Throws:
ConverterException
- if there was an error encoding the value
-
encode
Description copied from interface:PrimitiveEncoder
Encodes path.
- Specified by:
encode
in interfacePrimitiveEncoder<String>
- Parameters:
value
- the value to encode- Returns:
- an encoded value
- Throws:
ConverterException
- if there was an error encoding the value
-
encode
Description copied from interface:PrimitiveEncoder
Encodes URI.
- Specified by:
encode
in interfacePrimitiveEncoder<String>
- Parameters:
value
- the value to encode- Returns:
- an encoded value
- Throws:
ConverterException
- if there was an error encoding the value
-
encode
Description copied from interface:PrimitiveEncoder
Encodes URL.
- Specified by:
encode
in interfacePrimitiveEncoder<String>
- Parameters:
value
- the value to encode- Returns:
- an encoded value
- Throws:
ConverterException
- if there was an error encoding the value
-
encode
Description copied from interface:PrimitiveEncoder
Encodes pattern.
- Specified by:
encode
in interfacePrimitiveEncoder<String>
- Parameters:
value
- the value to encode- Returns:
- an encoded value
- Throws:
ConverterException
- if there was an error encoding the value
-
encode
Description copied from interface:PrimitiveEncoder
Encodes inet address.
- Specified by:
encode
in interfacePrimitiveEncoder<String>
- Parameters:
value
- the value to encode- Returns:
- an encoded value
- Throws:
ConverterException
- if there was an error encoding the value
-
encode
Description copied from interface:PrimitiveEncoder
Encodes inet socket address.
- Specified by:
encode
in interfacePrimitiveEncoder<String>
- Parameters:
value
- the value to encode- Returns:
- an encoded value
- Throws:
ConverterException
- if there was an error encoding the value
-
encode
Description copied from interface:PrimitiveEncoder
Encodes class.
- Specified by:
encode
in interfacePrimitiveEncoder<String>
- Parameters:
value
- the value to encode- Returns:
- an encoded value
- Throws:
ConverterException
- if there was an error encoding the value
-