Interface Encoder<R,T>
- Type Parameters:
R- The result type after encoding.T- The input type to be encoded.
- All Superinterfaces:
Codec<R,T>
- All Known Subinterfaces:
WebSocketSafeTypeEncoder<R,,T> WebSocketSafeTypeEncoder.TypeToByteArrayEncoder<T>,WebSocketSafeTypeEncoder.TypeToByteBufferEncoder<T>,WebSocketSafeTypeEncoder.TypeToJsonEncoder<T>,WebSocketSafeTypeEncoder.TypeToStringEncoder<T>
A generic interface for encoding data from one type into another.
Implementations of this interface are responsible for converting objects into an encoded format.
- Since:
- 3.5.0
-
Method Summary
-
Method Details
-
encode
Encodes the given input into its corresponding encoded representation.- Parameters:
t- The input to encode.- Returns:
- The encoded result.
-