- All Implemented Interfaces:
Converter<ByteBuf,,Object> Decoder<ByteBuf,,Object> Encoder<Object,,ByteBuf> JoinableEncoder<Object,,ByteBuf> JoinablePrimitiveEncoder<ByteBuf>,ObjectConverter<ByteBuf>,PrimitiveDecoder<ByteBuf>,PrimitiveEncoder<ByteBuf>,ReactiveConverter<ByteBuf,,Object> ReactiveDecoder<ByteBuf,,Object> ReactiveEncoder<Object,,ByteBuf> SplittableDecoder<ByteBuf,,Object> SplittablePrimitiveDecoder<ByteBuf>
- Direct Known Subclasses:
TextByteBufMediaTypeConverter
A Converter that encodes objects to ByteBuf and decodes ByteBuf to objects.
This implementation relies on a String ObjectConverter to convert the string representation of an object from/to ByteBufs.
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:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final byteThe default array/list separator -
Constructor Summary
ConstructorsConstructorDescriptionByteBufConverter(ObjectConverter<String> stringConverter) Creates a ByteBuf converter backed by the specified string converter, with default charset and array/list separator.ByteBufConverter(ObjectConverter<String> stringConverter, Charset charset, byte arrayListSeparator) Creates a ByteBuf converter backed by the specified string converter, with specified charset and array/list separator. -
Method Summary
Modifier and TypeMethodDescription<T> TDecodes the specified value to an object whose type is represented by the specified class.<T> TDecodes the specified value to an object of the specified type.decodeBigDecimal(ByteBuf value) Decodes to big decimal.decodeBigInteger(ByteBuf value) Decodes to big integer.decodeBoolean(ByteBuf value) Decodes to boolean.decodeByte(ByteBuf value) Decodes to byte.decodeCharacter(ByteBuf value) Decodes to character.<T> Class<T> decodeClass(ByteBuf value) Decodes to class.decodeCurrency(ByteBuf value) Decodes to currency.decodeDouble(ByteBuf value) Decodes to double.decodeFile(ByteBuf value) Decodes to file.decodeFloat(ByteBuf value) Decodes to float.decodeInetAddress(ByteBuf value) Decodes to inet address.decodeInetSocketAddress(ByteBuf value) Decodes to inet socket address.decodeInteger(ByteBuf value) Decodes to integer.decodeLocalDate(ByteBuf value) Decodes to local date.decodeLocalDateTime(ByteBuf value) Decodes to local datetime.decodeLocale(ByteBuf value) Decodes to locale.decodeLong(ByteBuf value) Decodes to long.<T> Flux<T> decodeMany(Publisher<ByteBuf> value, Class<T> type) Decodes the specified stream of values whose type is represented by the specified class into a flux stream of values.<T> Flux<T> decodeMany(Publisher<ByteBuf> value, Type type) Decodes the specified stream of values whose type is the specified type into a flux stream of values.<T> Mono<T> Decodes the specified stream of values whose type is represented by the specified class into a mono stream of values.<T> Mono<T> Decodes the specified stream of values whose type is the specified type into a mono stream of value.decodePath(ByteBuf value) Decodes to path.decodePattern(ByteBuf value) Decodes to pattern.decodeShort(ByteBuf value) Decodes to short.decodeString(ByteBuf value) Decodes to string.<T> T[]decodeToArray(ByteBuf 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(ByteBuf value, Type type) Decodes the specified value whose type is the specified type to an array of decoded values.<T> List<T> decodeToList(ByteBuf 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(ByteBuf value, Type type) Decodes the specified value whose type is the specified type to a list of decoded values.<T> Set<T> decodeToSet(ByteBuf 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(ByteBuf 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(ByteBuf 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> ByteBufencode(T value) Encodes the specified value to the encoded type.<T> ByteBufEncodes the specified value whose type is represented by the specified class to the encoded type.<T> ByteBufEncodes the specified value whose type is the specified type to the encoded type.<T> ByteBufencodeArray(T[] value) Encodes the specified array of values to the encoded type.<T> ByteBufencodeArray(T[] value, Class<T> type) Encodes the specified array of values whose type is represented by the specified class to the encoded type.<T> ByteBufencodeArray(T[] value, Type type) Encodes the specified array of values whose type is represented by the specified class to the encoded type.<T> ByteBufencodeList(List<T> value) Encodes the specified list of values to an encoded value.<T> ByteBufencodeList(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> ByteBufencodeList(List<T> value, Type type) Encodes the specified list of values whose type is the specified type to an encoded value.encodeMany(Flux<T> value) Encodes a flux stream of values to a stream of values.encodeMany(Flux<T> value, Class<T> type) Encodes a flux stream of values whose type is represented by the specified class to a stream of values.encodeMany(Flux<T> value, Type type) Encodes a flux stream of values whose type is the specified type to a stream of values.Encodes a mono stream of values to a stream of values.Encodes a mono stream of values whose type is represented by the specified class to a stream of values.Encodes a mono stream of values whose type is the specified type to a stream of values.<T> ByteBufEncodes the specified set of values to an encoded value.<T> ByteBufEncodes the specified set of values whose type is represented by the specified class to an encoded value.<T> ByteBufEncodes the specified set of values whose type is the specified type to an encoded value.byteReturns the array/list separator used to convert lists and arrays.Returns the charset used to serialize/deserialize to/from ByteBuf.voidsetArrayListSeparator(byte arrayListSeparator) Sets the array/list separator used to convert lists and arrays.voidsetCharset(Charset charset) Sets the charset used to serialize/deserialize to/from ByteBuf.
-
Field Details
-
DEFAULT_ARRAY_LIST_SEPARATOR
public static final byte DEFAULT_ARRAY_LIST_SEPARATORThe default array/list separator- See Also:
-
-
Constructor Details
-
ByteBufConverter
Creates a ByteBuf converter backed by the specified string converter, with default charset and array/list separator.
- Parameters:
stringConverter- a string converter
-
ByteBufConverter
public ByteBufConverter(ObjectConverter<String> stringConverter, Charset charset, byte arrayListSeparator) Creates a ByteBuf converter backed by the specified string converter, with specified charset and array/list separator.
- Parameters:
stringConverter- A string convertercharset- the charsetarrayListSeparator- the array/list separator
-
-
Method Details
-
getCharset
Returns the charset used to serialize/deserialize to/from ByteBuf.
- Returns:
- a charset
-
setCharset
Sets the charset used to serialize/deserialize to/from ByteBuf.
- Parameters:
charset- a charset
-
getArrayListSeparator
public byte getArrayListSeparator()Returns the array/list separator used to convert lists and arrays.
- Returns:
- an array/list separator
-
setArrayListSeparator
public void setArrayListSeparator(byte arrayListSeparator) Sets the array/list separator used to convert lists and arrays.
- Parameters:
arrayListSeparator- an array/list separator
-
decodeOne
Description copied from interface:ReactiveDecoderDecodes the specified stream of values whose type is represented by the specified class into a mono stream of values.
- Specified by:
decodeOnein interfaceReactiveDecoder<ByteBuf,Object> - Type Parameters:
T- the type of the decoded object- Parameters:
value- the stream of values to decodetype- the class of the decoded object- Returns:
- a mono emitting the decoded value
-
decodeOne
Description copied from interface:ReactiveDecoderDecodes the specified stream of values whose type is the specified type into a mono stream of value.
- Specified by:
decodeOnein interfaceReactiveDecoder<ByteBuf,Object> - Type Parameters:
T- the type of the decoded object- Parameters:
value- the stream of values to decodetype- the type of the decoded object- Returns:
- a mono emitting the decoded value
-
decodeMany
Description copied from interface:ReactiveDecoderDecodes the specified stream of values whose type is represented by the specified class into a flux stream of values.
- Specified by:
decodeManyin interfaceReactiveDecoder<ByteBuf,Object> - Type Parameters:
T- the type of the decoded object- Parameters:
value- the stream of values to decodetype- the class of the decoded object- Returns:
- a flux emitting the decoded values
-
decodeMany
Description copied from interface:ReactiveDecoderDecodes the specified stream of values whose type is the specified type into a flux stream of values.
- Specified by:
decodeManyin interfaceReactiveDecoder<ByteBuf,Object> - Type Parameters:
T- the type of the decoded object- Parameters:
value- the stream of values to decodetype- the type of the decoded object- Returns:
- a flux emitting the decoded values
-
decode
Description copied from interface:DecoderDecodes the specified value to an object whose type is represented by the specified class.
-
decode
Description copied from interface:DecoderDecodes the specified value to an object of the specified type.
- Specified by:
decodein interfaceDecoder<ByteBuf,Object> - Type Parameters:
T- the type of the decoded object- Parameters:
value- the object to decodetype- the type of the decoded object- Returns:
- a decoded object
- Throws:
ConverterException- if there was an error decoding the value
-
decodeToList
Description copied from interface:SplittableDecoderDecodes the specified value whose type is represented by the specified class to a list of decoded values.
- Specified by:
decodeToListin interfaceSplittableDecoder<ByteBuf,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:SplittableDecoderDecodes the specified value whose type is the specified type to a list of decoded values.
- Specified by:
decodeToListin interfaceSplittableDecoder<ByteBuf,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:SplittableDecoderDecodes the specified value whose type is represented by the specified class to a set of decoded values.
- Specified by:
decodeToSetin interfaceSplittableDecoder<ByteBuf,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:SplittableDecoderDecodes the specified value whose type is the specified type to a set of decoded values.
- Specified by:
decodeToSetin interfaceSplittableDecoder<ByteBuf,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:SplittableDecoderDecodes the specified value whose type is represented by the specified class to an array of decoded values.
- Specified by:
decodeToArrayin interfaceSplittableDecoder<ByteBuf,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:SplittableDecoderDecodes the specified value whose type is the specified type to an array of decoded values.
- Specified by:
decodeToArrayin interfaceSplittableDecoder<ByteBuf,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:PrimitiveDecoderDecodes to byte.
- Specified by:
decodeBytein interfacePrimitiveDecoder<ByteBuf>- 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:PrimitiveDecoderDecodes to short.
- Specified by:
decodeShortin interfacePrimitiveDecoder<ByteBuf>- 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:PrimitiveDecoderDecodes to integer.
- Specified by:
decodeIntegerin interfacePrimitiveDecoder<ByteBuf>- 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:PrimitiveDecoderDecodes to long.
- Specified by:
decodeLongin interfacePrimitiveDecoder<ByteBuf>- 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:PrimitiveDecoderDecodes to float.
- Specified by:
decodeFloatin interfacePrimitiveDecoder<ByteBuf>- 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:PrimitiveDecoderDecodes to double.
- Specified by:
decodeDoublein interfacePrimitiveDecoder<ByteBuf>- 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:PrimitiveDecoderDecodes to character.
- Specified by:
decodeCharacterin interfacePrimitiveDecoder<ByteBuf>- 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:PrimitiveDecoderDecodes to boolean.
- Specified by:
decodeBooleanin interfacePrimitiveDecoder<ByteBuf>- 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:PrimitiveDecoderDecodes to string.
- Specified by:
decodeStringin interfacePrimitiveDecoder<ByteBuf>- 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:PrimitiveDecoderDecodes to big integer.
- Specified by:
decodeBigIntegerin interfacePrimitiveDecoder<ByteBuf>- 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:PrimitiveDecoderDecodes to big decimal.
- Specified by:
decodeBigDecimalin interfacePrimitiveDecoder<ByteBuf>- 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:PrimitiveDecoderDecodes to local date.
- Specified by:
decodeLocalDatein interfacePrimitiveDecoder<ByteBuf>- 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:PrimitiveDecoderDecodes to local datetime.
- Specified by:
decodeLocalDateTimein interfacePrimitiveDecoder<ByteBuf>- 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:PrimitiveDecoderDecodes to zoned datetime.
- Specified by:
decodeZonedDateTimein interfacePrimitiveDecoder<ByteBuf>- 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:PrimitiveDecoderDecodes to currency.
- Specified by:
decodeCurrencyin interfacePrimitiveDecoder<ByteBuf>- 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:PrimitiveDecoderDecodes to locale.
- Specified by:
decodeLocalein interfacePrimitiveDecoder<ByteBuf>- 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:PrimitiveDecoderDecodes to file.
- Specified by:
decodeFilein interfacePrimitiveDecoder<ByteBuf>- 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:PrimitiveDecoderDecodes to path.
- Specified by:
decodePathin interfacePrimitiveDecoder<ByteBuf>- 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:PrimitiveDecoderDecodes to URI.
- Specified by:
decodeURIin interfacePrimitiveDecoder<ByteBuf>- 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:PrimitiveDecoderDecodes to URL.
- Specified by:
decodeURLin interfacePrimitiveDecoder<ByteBuf>- 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:PrimitiveDecoderDecodes to pattern.
- Specified by:
decodePatternin interfacePrimitiveDecoder<ByteBuf>- 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:PrimitiveDecoderDecodes to inet address.
- Specified by:
decodeInetAddressin interfacePrimitiveDecoder<ByteBuf>- 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:PrimitiveDecoderDecodes to inet socket address.
- Specified by:
decodeInetSocketAddressin interfacePrimitiveDecoder<ByteBuf>- 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:PrimitiveDecoderDecodes to class.
- Specified by:
decodeClassin interfacePrimitiveDecoder<ByteBuf>- Type Parameters:
T- the target class type- Parameters:
value- the encoded value to decode- Returns:
- a decoded value
- Throws:
ConverterException- if there was an error decoding the value
-
encodeOne
Description copied from interface:ReactiveEncoderEncodes a mono stream of values to a stream of values.
- Specified by:
encodeOnein interfaceReactiveEncoder<Object,ByteBuf> - Type Parameters:
T- the type of the decoded object- Parameters:
value- the mono stream of values to encode- Returns:
- a stream of encoded values
-
encodeOne
Description copied from interface:ReactiveEncoderEncodes a mono stream of values whose type is represented by the specified class to a stream of values.
- Specified by:
encodeOnein interfaceReactiveEncoder<Object,ByteBuf> - Type Parameters:
T- the type of the decoded object- Parameters:
value- the mono stream of values to encodetype- the class of the decoded object- Returns:
- a stream of encoded values
-
encodeOne
Description copied from interface:ReactiveEncoderEncodes a mono stream of values whose type is the specified type to a stream of values.
- Specified by:
encodeOnein interfaceReactiveEncoder<Object,ByteBuf> - Type Parameters:
T- the type of the decoded object- Parameters:
value- the mono stream of values to encodetype- the type of the decoded object- Returns:
- a stream of encoded values
-
encodeMany
Description copied from interface:ReactiveEncoderEncodes a flux stream of values to a stream of values.
- Specified by:
encodeManyin interfaceReactiveEncoder<Object,ByteBuf> - Type Parameters:
T- the type of the decoded object- Parameters:
value- the flux stream of values to encode- Returns:
- a stream of encoded values
-
encodeMany
Description copied from interface:ReactiveEncoderEncodes a flux stream of values whose type is represented by the specified class to a stream of values.
- Specified by:
encodeManyin interfaceReactiveEncoder<Object,ByteBuf> - Type Parameters:
T- the type of the decoded object- Parameters:
value- the flux stream of values to encodetype- the class of the decoded object- Returns:
- a stream of encoded values
-
encodeMany
Description copied from interface:ReactiveEncoderEncodes a flux stream of values whose type is the specified type to a stream of values.
- Specified by:
encodeManyin interfaceReactiveEncoder<Object,ByteBuf> - Type Parameters:
T- the type of the decoded object- Parameters:
value- the flux stream of values to encodetype- the type of the decoded object- Returns:
- a stream of encoded values
-
encode
Description copied from interface:EncoderEncodes the specified value to the encoded type.
-
encode
Description copied from interface:EncoderEncodes the specified value whose type is represented by the specified class to the encoded type.
- Specified by:
encodein interfaceEncoder<Object,ByteBuf> - Type Parameters:
T- the type of the decoded object- Parameters:
value- the object to encodetype- the class of the decoded object- Returns:
- an encoded object
- Throws:
ConverterException- if there was an error encoding the value
-
encode
Description copied from interface:EncoderEncodes the specified value whose type is the specified type to the encoded type.
- Specified by:
encodein interfaceEncoder<Object,ByteBuf> - Type Parameters:
T- the type of the decoded object- Parameters:
value- the object to encodetype- the type of the decoded object- Returns:
- an encoded object
- Throws:
ConverterException- if there was an error encoding the value
-
encodeList
Description copied from interface:JoinableEncoderEncodes the specified list of values to an encoded value.
- Specified by:
encodeListin interfaceJoinableEncoder<Object,ByteBuf> - 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:JoinableEncoderEncodes the specified list of values whose type is represented by the specified class to an encoded value.
- Specified by:
encodeListin interfaceJoinableEncoder<Object,ByteBuf> - 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:JoinableEncoderEncodes the specified list of values whose type is the specified type to an encoded value.
- Specified by:
encodeListin interfaceJoinableEncoder<Object,ByteBuf> - 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:JoinableEncoderEncodes the specified set of values to an encoded value.
- Specified by:
encodeSetin interfaceJoinableEncoder<Object,ByteBuf> - 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:JoinableEncoderEncodes the specified set of values whose type is represented by the specified class to an encoded value.
- Specified by:
encodeSetin interfaceJoinableEncoder<Object,ByteBuf> - 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:JoinableEncoderEncodes the specified set of values whose type is the specified type to an encoded value.
- Specified by:
encodeSetin interfaceJoinableEncoder<Object,ByteBuf> - 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:JoinableEncoderEncodes the specified array of values to the encoded type.
- Specified by:
encodeArrayin interfaceJoinableEncoder<Object,ByteBuf> - 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:JoinableEncoderEncodes the specified array of values whose type is represented by the specified class to the encoded type.
- Specified by:
encodeArrayin interfaceJoinableEncoder<Object,ByteBuf> - 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:JoinableEncoderEncodes the specified array of values whose type is represented by the specified class to the encoded type.
- Specified by:
encodeArrayin interfaceJoinableEncoder<Object,ByteBuf> - 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:PrimitiveEncoderEncodes byte.
- Specified by:
encodein interfacePrimitiveEncoder<ByteBuf>- 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:PrimitiveEncoderEncodes short.
- Specified by:
encodein interfacePrimitiveEncoder<ByteBuf>- 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:PrimitiveEncoderEncodes integer.
- Specified by:
encodein interfacePrimitiveEncoder<ByteBuf>- 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:PrimitiveEncoderEncodes long.
- Specified by:
encodein interfacePrimitiveEncoder<ByteBuf>- 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:PrimitiveEncoderEncodes float.
- Specified by:
encodein interfacePrimitiveEncoder<ByteBuf>- 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:PrimitiveEncoderEncodes double.
- Specified by:
encodein interfacePrimitiveEncoder<ByteBuf>- 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:PrimitiveEncoderEncodes character.
- Specified by:
encodein interfacePrimitiveEncoder<ByteBuf>- 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:PrimitiveEncoderEncodes boolean.
- Specified by:
encodein interfacePrimitiveEncoder<ByteBuf>- 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:PrimitiveEncoderEncodes string.
- Specified by:
encodein interfacePrimitiveEncoder<ByteBuf>- 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:PrimitiveEncoderEncodes big integer.
- Specified by:
encodein interfacePrimitiveEncoder<ByteBuf>- 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:PrimitiveEncoderEncodes big decimal.
- Specified by:
encodein interfacePrimitiveEncoder<ByteBuf>- 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:PrimitiveEncoderEncodes local date.
- Specified by:
encodein interfacePrimitiveEncoder<ByteBuf>- 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:PrimitiveEncoderEncodes local datetime.
- Specified by:
encodein interfacePrimitiveEncoder<ByteBuf>- 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:PrimitiveEncoderEncodes zoned datetime.
- Specified by:
encodein interfacePrimitiveEncoder<ByteBuf>- 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:PrimitiveEncoderEncodes currency.
- Specified by:
encodein interfacePrimitiveEncoder<ByteBuf>- 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:PrimitiveEncoderEncodes locale.
- Specified by:
encodein interfacePrimitiveEncoder<ByteBuf>- 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:PrimitiveEncoderEncodes file.
- Specified by:
encodein interfacePrimitiveEncoder<ByteBuf>- 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:PrimitiveEncoderEncodes path.
- Specified by:
encodein interfacePrimitiveEncoder<ByteBuf>- 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:PrimitiveEncoderEncodes URI.
- Specified by:
encodein interfacePrimitiveEncoder<ByteBuf>- 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:PrimitiveEncoderEncodes URL.
- Specified by:
encodein interfacePrimitiveEncoder<ByteBuf>- 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:PrimitiveEncoderEncodes pattern.
- Specified by:
encodein interfacePrimitiveEncoder<ByteBuf>- 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:PrimitiveEncoderEncodes inet address.
- Specified by:
encodein interfacePrimitiveEncoder<ByteBuf>- 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:PrimitiveEncoderEncodes inet socket address.
- Specified by:
encodein interfacePrimitiveEncoder<ByteBuf>- 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:PrimitiveEncoderEncodes class.
- Specified by:
encodein interfacePrimitiveEncoder<ByteBuf>- Parameters:
value- the value to encode- Returns:
- an encoded value
- Throws:
ConverterException- if there was an error encoding the value
-