public class CollectionCoder<T> extends IterableLikeCoder<T,java.util.Collection<T>>
Coder.Context, Coder.NonDeterministicException
Modifier | Constructor and Description |
---|---|
protected |
CollectionCoder(Coder<T> elemCoder) |
Modifier and Type | Method and Description |
---|---|
protected java.util.Collection<T> |
decodeToIterable(java.util.List<T> decodedElements)
Builds an instance of
IterableT , this coder's associated Iterable -like
subtype, from a list of decoded elements. |
TypeDescriptor<java.util.Collection<T>> |
getEncodedTypeDescriptor()
Returns the
TypeDescriptor for the type encoded. |
static <T> CollectionCoder<T> |
of(Coder<T> elemCoder) |
decode, encode, getCoderArguments, getElemCoder, isRegisterByteSizeObserverCheap, registerByteSizeObserver, verifyDeterministic
equals, getComponents, hashCode, toString
consistentWithEquals, decode, encode, getEncodedElementByteSize, structuralValue, verifyDeterministic, verifyDeterministic
public static <T> CollectionCoder<T> of(Coder<T> elemCoder)
protected final java.util.Collection<T> decodeToIterable(java.util.List<T> decodedElements)
IterableT
, this coder's associated Iterable
-like
subtype, from a list of decoded elements.decodeToIterable
in class IterableLikeCoder<T,java.util.Collection<T>>
List
is a subtype of
Collection
.public TypeDescriptor<java.util.Collection<T>> getEncodedTypeDescriptor()
Coder
TypeDescriptor
for the type encoded.getEncodedTypeDescriptor
in class Coder<java.util.Collection<T>>