Class DecoderPair<T>
java.lang.Object
de.craftsblock.craftsnet.api.codec.CodecPair<T,Decoder<T,?>>
de.craftsblock.craftsnet.api.codec.DecoderPair<T>
- Type Parameters:
T- The target type to be decoded.
A pairing between a specific target type and its associated
Decoder.
This class allows registration or lookup of decoders based on the target type they support.
-
Constructor Summary
ConstructorsConstructorDescriptionDecoderPair(Class<T> target, Decoder<T, ?> codec) Constructs a newDecoderPairfor the given target type and decoder. -
Method Summary
Methods inherited from class de.craftsblock.craftsnet.api.codec.CodecPair
asCodecSubtype, canCodecType, getCodec, getTarget
-
Constructor Details
-
DecoderPair
Constructs a newDecoderPairfor the given target type and decoder.- Parameters:
target- The type the decoder can decode to.codec- The decoder instance.
-