Interface TransformTranslator.StepTranslationContext

Enclosing interface:
TransformTranslator<TransformT extends PTransform>

public static interface TransformTranslator.StepTranslationContext
The interface for a TransformTranslator to build a Dataflow step.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    addCollectionToSingletonOutput(PCollection<?> inputValue, String outputName, PCollectionView<?> outputValue)
    Adds an output to this CollectionToSingleton Dataflow step, consuming the specified input PValue and producing the specified output PValue.
    void
    Sets the encoding for this Dataflow step.
    void
    addInput(String name, Boolean value)
    Adds an input with the given name and value to this Dataflow step.
    void
    addInput(String name, Long value)
    Adds an input with the given name and value to this Dataflow step.
    void
    addInput(String name, String value)
    Adds an input with the given name and value to this Dataflow step.
    void
    addInput(String name, List<? extends Map<String,Object>> elements)
    Adds an input that is a list of objects.
    void
    addInput(String name, Map<String,Object> elements)
    Adds an input that is a dictionary of strings to objects.
    void
    addInput(String name, PInput value)
    Adds an input with the given name to this Dataflow step, coming from the specified input PValue.
    void
    addOutput(String name, PCollection<?> value)
    Adds a primitive output to this Dataflow step with the given name as the local output name, producing the specified output PValue, including its Coder if a TypedPValue.
  • Method Details

    • addEncodingInput

      void addEncodingInput(Coder<?> value)
      Sets the encoding for this Dataflow step.
    • addInput

      void addInput(String name, Boolean value)
      Adds an input with the given name and value to this Dataflow step.
    • addInput

      void addInput(String name, String value)
      Adds an input with the given name and value to this Dataflow step.
    • addInput

      void addInput(String name, Long value)
      Adds an input with the given name and value to this Dataflow step.
    • addInput

      void addInput(String name, PInput value)
      Adds an input with the given name to this Dataflow step, coming from the specified input PValue.

      The input PValue must have already been produced by a step earlier in this Pipeline. If the input value has not yet been produced yet (by a call to either addOutput(java.lang.String, org.apache.beam.sdk.values.PCollection<?>) or addCollectionToSingletonOutput(org.apache.beam.sdk.values.PCollection<?>, java.lang.String, org.apache.beam.sdk.values.PCollectionView<?>)) this method will throw an exception.

    • addInput

      void addInput(String name, Map<String,Object> elements)
      Adds an input that is a dictionary of strings to objects.
    • addInput

      void addInput(String name, List<? extends Map<String,Object>> elements)
      Adds an input that is a list of objects.
    • addOutput

      void addOutput(String name, PCollection<?> value)
      Adds a primitive output to this Dataflow step with the given name as the local output name, producing the specified output PValue, including its Coder if a TypedPValue. If the PValue is a PCollection, wraps its coder inside a WindowedValueCoder.
    • addCollectionToSingletonOutput

      void addCollectionToSingletonOutput(PCollection<?> inputValue, String outputName, PCollectionView<?> outputValue)
      Adds an output to this CollectionToSingleton Dataflow step, consuming the specified input PValue and producing the specified output PValue. This step requires special treatment for its output encoding. Returns a pipeline level unique id.