Package io.grpc
Interface Metadata.BinaryMarshaller<T>
-
- Enclosing class:
- Metadata
public static interface Metadata.BinaryMarshaller<T>
Marshaller for metadata values that are serialized into raw binary.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description T
parseBytes(byte[] serialized)
Parse a serialized metadata value from bytes.byte[]
toBytes(T value)
Serialize a metadata value to bytes.
-
-
-
Method Detail
-
toBytes
byte[] toBytes(T value)
Serialize a metadata value to bytes.- Parameters:
value
- to serialize- Returns:
- serialized version of value
-
parseBytes
T parseBytes(byte[] serialized)
Parse a serialized metadata value from bytes.- Parameters:
serialized
- value of metadata to parse- Returns:
- a parsed instance of type T
-
-