Package net.minecraft.util
Class StringRepresentable.StringRepresentableCodec<S extends StringRepresentable>
java.lang.Object
net.minecraft.util.StringRepresentable.StringRepresentableCodec<S>
- All Implemented Interfaces:
com.mojang.serialization.Codec<S>
,com.mojang.serialization.Decoder<S>
,com.mojang.serialization.Encoder<S>
- Direct Known Subclasses:
StringRepresentable.EnumCodec
- Enclosing interface:
- StringRepresentable
public static class StringRepresentable.StringRepresentableCodec<S extends StringRepresentable>
extends Object
implements com.mojang.serialization.Codec<S>
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.mojang.serialization.Codec
com.mojang.serialization.Codec.ResultFunction<A extends Object>
-
Field Summary
Fields inherited from interface com.mojang.serialization.Codec
BOOL, BYTE, BYTE_BUFFER, DOUBLE, EMPTY, FLOAT, INT, INT_STREAM, LONG, LONG_STREAM, PASSTHROUGH, SHORT, STRING
-
Constructor Summary
ConstructorDescriptionStringRepresentableCodec
(S[] p_309730_, Function<String, S> p_311107_, ToIntFunction<S> p_312549_) -
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.mojang.serialization.Codec
comapFlatMap, deprecated, dispatch, dispatch, dispatchMap, dispatchMap, dispatchStable, fieldOf, flatComapMap, flatXmap, listOf, mapResult, optionalFieldOf, optionalFieldOf, optionalFieldOf, optionalFieldOf, orElse, orElse, orElse, orElseGet, orElseGet, orElseGet, partialDispatch, promotePartial, stable, withLifecycle, xmap
Methods inherited from interface com.mojang.serialization.Decoder
boxed, decode, flatMap, map, parse, parse, simple, terminal
Methods inherited from interface com.mojang.serialization.Encoder
comap, encodeStart, flatComap
-
Field Details
-
codec
-
-
Constructor Details
-
StringRepresentableCodec
-
-
Method Details
-
decode
public <T> com.mojang.serialization.DataResult<com.mojang.datafixers.util.Pair<S,T>> decode(com.mojang.serialization.DynamicOps<T> p_310491_, T p_312317_) - Specified by:
decode
in interfacecom.mojang.serialization.Decoder<S extends StringRepresentable>
-
encode
public <T> com.mojang.serialization.DataResult<T> encode(S p_312413_, com.mojang.serialization.DynamicOps<T> p_310685_, T p_312430_) - Specified by:
encode
in interfacecom.mojang.serialization.Encoder<S extends StringRepresentable>
-