public class PCollectionViews extends Object
PCollectionView shared across the SDK.
For internal use only, subject to change.
| Constructor and Description |
|---|
PCollectionViews() |
| Modifier and Type | Method and Description |
|---|---|
static <T,W extends BoundedWindow> |
iterableView(Pipeline pipeline,
WindowingStrategy<?,W> windowingStrategy,
Coder<T> valueCoder)
Returns a
PCollectionView<Iterable<T>> capable of processing elements encoded using the
provided Coder and windowed using the provided WindowingStrategy. |
static <K,V,W extends BoundedWindow> |
mapView(Pipeline pipeline,
WindowingStrategy<?,W> windowingStrategy,
Coder<KV<K,V>> valueCoder)
Returns a
PCollectionView<Map<K, V>> capable of processing elements encoded using the
provided Coder and windowed using the provided WindowingStrategy. |
static <K,V,W extends BoundedWindow> |
multimapView(Pipeline pipeline,
WindowingStrategy<?,W> windowingStrategy,
Coder<KV<K,V>> valueCoder)
Returns a
PCollectionView<Map<K, Iterable<V>>> capable of processing elements encoded
using the provided Coder and windowed using the provided WindowingStrategy. |
static <T,W extends BoundedWindow> |
singletonView(Pipeline pipeline,
WindowingStrategy<?,W> windowingStrategy,
boolean hasDefault,
T defaultValue,
Coder<T> valueCoder)
Returns a
PCollectionView<T> capable of processing elements encoded using the provided
Coder and windowed using the provided * WindowingStrategy. |
public static <T,W extends BoundedWindow> PCollectionView<T> singletonView(Pipeline pipeline, WindowingStrategy<?,W> windowingStrategy, boolean hasDefault, T defaultValue, Coder<T> valueCoder)
PCollectionView<T> capable of processing elements encoded using the provided
Coder and windowed using the provided * WindowingStrategy.
If hasDefault is true, then the view will take on the value
defaultValue for any empty windows.
public static <T,W extends BoundedWindow> PCollectionView<Iterable<T>> iterableView(Pipeline pipeline, WindowingStrategy<?,W> windowingStrategy, Coder<T> valueCoder)
PCollectionView<Iterable<T>> capable of processing elements encoded using the
provided Coder and windowed using the provided WindowingStrategy.public static <K,V,W extends BoundedWindow> PCollectionView<Map<K,V>> mapView(Pipeline pipeline, WindowingStrategy<?,W> windowingStrategy, Coder<KV<K,V>> valueCoder)
PCollectionView<Map<K, V>> capable of processing elements encoded using the
provided Coder and windowed using the provided WindowingStrategy.public static <K,V,W extends BoundedWindow> PCollectionView<Map<K,Iterable<V>>> multimapView(Pipeline pipeline, WindowingStrategy<?,W> windowingStrategy, Coder<KV<K,V>> valueCoder)
PCollectionView<Map<K, Iterable<V>>> capable of processing elements encoded
using the provided Coder and windowed using the provided WindowingStrategy.