Interface ByteArrayEncoder<T>
-
- Type Parameters:
T- The encoded item data type
- All Known Subinterfaces:
ByteArrayCodec<T>
- All Known Implementing Classes:
DelegatingByteArrayCodec
public interface ByteArrayEncoder<T>A functional interface for encoders producing byte arrays representing single items. In contract toItemEncoder, this encoder should always be stateless, and is suitable for cases where the encoded form is required to be a byte array, whose bytes represent a single item.- Author:
- Eyal Schneider
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description byte[]encode(T item)
-
-
-
Method Detail
-
encode
byte[] encode(T item)
- Parameters:
item- The item to encode- Returns:
- The encoded item, as byte array
-
-