com.mojang.serialization.codecs

public final class EitherMapCodec<F, S>

extends MapCodec<Either<F, S>>

All mapped superinterfaces:

Compressable, Keyable, MapDecoder, MapEncoder

com.mojang.serialization.codecs.EitherMapCodec

Field summary

Modifier and TypeField
private final MapCodec<F>
first
private final MapCodec<S>
second

Constructor summary

ModifierConstructor
public (MapCodec<F> arg0, MapCodec<S> arg1)

Method summary

Modifier and TypeMethod
public <T> DataResult<Either<F, S>>
decode(DynamicOps<T> arg0, MapLike<T> arg1)
public <T> RecordBuilder<T>
encode(Either<F, S> arg0, DynamicOps<T> arg1, RecordBuilder<T> arg2)
public <T> Stream<T>
keys(DynamicOps<T> arg0)