Class DfuSerializers
- java.lang.Object
- 
- org.spongepowered.configurate.extra.dfu.v3.DfuSerializers
 
- 
 public final class DfuSerializers extends Object A bridge between Configurate and DataFixerUpper serialization systems.- Since:
- 4.0.0
 
- 
- 
Method SummaryAll Methods Static Methods Concrete Methods Modifier and Type Method Description static <S> @Nullable Codec<S>codec(TypeToken<S> type)Create a new codec that uses the default type serializer collection to serialize an object of the provided type.static <V> @Nullable Codec<V>codec(TypeToken<V> type, TypeSerializerCollection collection)Create a new codec based on a ConfigurateTypeSerializer.static <V> TypeSerializer<V>serializer(Codec<V> codec)Create a new serializer wrapping the providedCodec.
 
- 
- 
- 
Method Detail- 
serializerpublic static <V> TypeSerializer<V> serializer(Codec<V> codec) Create a new serializer wrapping the providedCodec.- Type Parameters:
- V- value type
- Parameters:
- codec- codec to use for the serialization operation
- Returns:
- a new serializer
- Since:
- 4.0.0
 
 - 
codecpublic static <S> @Nullable Codec<S> codec(TypeToken<S> type) Create a new codec that uses the default type serializer collection to serialize an object of the provided type.- Type Parameters:
- S- value type
- Parameters:
- type- token representing a value type
- Returns:
- a codec for the type, or null if an appropriate
      TypeSerializercould not be found.
- Since:
- 4.0.0
 
 - 
codecpublic static <V> @Nullable Codec<V> codec(TypeToken<V> type, TypeSerializerCollection collection) Create a new codec based on a ConfigurateTypeSerializer.- Type Parameters:
- V- value type
- Parameters:
- type- type to serialize
- collection- source for values
- Returns:
- a codec, or null if an appropriate TypeSerializercould not be found for the TypeToken.
- Since:
- 4.0.0
 
 
- 
 
-