Package javax.websocket
Interface Decoder.Binary<T>
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface javax.websocket.Decoder
Decoder.Binary<T>, Decoder.BinaryStream<T>, Decoder.Text<T>, Decoder.TextStream<T>
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description Tdecode(java.nio.ByteBuffer bytes)Decode the given bytes into an object of type T.booleanwillDecode(java.nio.ByteBuffer bytes)Answer whether the given bytes can be decoded into an object of type T.
-
-
-
Method Detail
-
decode
T decode(java.nio.ByteBuffer bytes) throws DecodeException
Decode the given bytes into an object of type T.- Parameters:
bytes- the bytes to be decoded.- Returns:
- the decoded object.
- Throws:
DecodeException
-
willDecode
boolean willDecode(java.nio.ByteBuffer bytes)
Answer whether the given bytes can be decoded into an object of type T.- Parameters:
bytes- the bytes to be decoded.- Returns:
- whether or not the bytes can be decoded by this decoder.
-
-