T - the type of the elements of the Lists being transcodedpublic class ListCoder<T> extends IterableLikeCoder<T,List<T>>
Coder.Context, Coder.NonDeterministicException| Modifier | Constructor and Description |
|---|---|
protected |
ListCoder(Coder<T> elemCoder) |
| Modifier and Type | Method and Description |
|---|---|
protected List<T> |
decodeToIterable(List<T> decodedElements)
Builds an instance of
IterableT, this coder's associated Iterable-like
subtype, from a list of decoded elements. |
static <T> List<Object> |
getInstanceComponents(List<T> exampleValue)
Returns the first element in this list if it is non-empty,
otherwise returns
null. |
static <T> ListCoder<T> |
of(Coder<T> elemCoder) |
static ListCoder<?> |
of(List<Coder<?>> components) |
void |
verifyDeterministic()
List sizes are always known, so ListIterable may be deterministic while
the general IterableLikeCoder is not.
|
decode, encode, getCoderArguments, getElemCoder, getInstanceComponentsHelper, isRegisterByteSizeObserverCheap, registerByteSizeObserverasCloudObject, consistentWithEquals, equals, getAllowedEncodings, getComponents, getEncodedElementByteSize, getEncodingId, hashCode, structuralValue, toString, verifyDeterministic, verifyDeterministicprotected final List<T> decodeToIterable(List<T> decodedElements)
IterableLikeCoderIterableT, this coder's associated Iterable-like
subtype, from a list of decoded elements.decodeToIterable in class IterableLikeCoder<T,List<T>>public static <T> List<Object> getInstanceComponents(List<T> exampleValue)
null.public void verifyDeterministic()
throws Coder.NonDeterministicException
verifyDeterministic in interface Coder<List<T>>verifyDeterministic in class IterableLikeCoder<T,List<T>>Coder.NonDeterministicException - if this coder is not deterministic.