Top Description Fields Constructors Methods
org.eclipse.jetty.ee10.websocket.jakarta.common.decoders

public Class ShortDecoder

extends AbstractDecoder
implements Decoder.Text<Short>
Class Inheritance
All Implemented Interfaces
jakarta.websocket.Decoder.Text, jakarta.websocket.Decoder
Imports
jakarta.websocket.DecodeException, .Decoder

Default implementation of the jakarta.websocket.Decoder.Text Message to Short decoder

Field Summary

Modifier and TypeField and Description
public static final ShortDecoder

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public Short
decode(String
string to be decoded.
s
)

Implements jakarta.websocket.Decoder.Text.decode.

Decode the given String into an object of type T.

public boolean
willDecode(String
the string being tested for decodability.
s
)

Implements jakarta.websocket.Decoder.Text.willDecode.

Answer whether the given String can be decoded into an object of type T.

Inherited from org.eclipse.jetty.ee10.websocket.jakarta.common.decoders.AbstractDecoder:
destroyinit

Field Detail

INSTANCEback to summary
public static final ShortDecoder INSTANCE

Constructor Detail

ShortDecoderback to summary
public ShortDecoder()

Method Detail

decodeback to summary
public Short decode(String s) throws DecodeException

Implements jakarta.websocket.Decoder.Text.decode.

Doc from jakarta.websocket.Decoder.Text.decode.

Decode the given String into an object of type T.

Parameters
s:String

string to be decoded.

Returns:Short

the decoded message as an object of type T

Annotations
@Override
Exceptions
DecodeException:
If the provided string cannot be decoded to type T
willDecodeback to summary
public boolean willDecode(String s)

Implements jakarta.websocket.Decoder.Text.willDecode.

Doc from jakarta.websocket.Decoder.Text.willDecode.

Answer whether the given String can be decoded into an object of type T.

Parameters
s:String

the string being tested for decodability.

Returns:boolean

whether this decoder can decoded the supplied string.

Annotations
@Override