public static class BigQueryIO.Write.Bound extends PTransform<PCollection<com.google.api.services.bigquery.model.TableRow>,PDone>
PTransform that can write either a bounded or unbounded
PCollection of TableRows to a BigQuery table.name| Constructor and Description |
|---|
Bound() |
| Modifier and Type | Method and Description |
|---|---|
PDone |
apply(PCollection<com.google.api.services.bigquery.model.TableRow> input)
Applies this
PTransform on the given InputT, and returns its
Output. |
BigQueryIO.Write.CreateDisposition |
getCreateDisposition()
Returns the create disposition.
|
protected Coder<Void> |
getDefaultOutputCoder()
Returns the default
Coder to use for the output of this
single-output PTransform. |
com.google.api.services.bigquery.model.TableSchema |
getSchema()
Returns the table schema.
|
com.google.api.services.bigquery.model.TableReference |
getTable()
Returns the table reference.
|
boolean |
getValidate()
Returns true if table validation is enabled.
|
BigQueryIO.Write.WriteDisposition |
getWriteDisposition()
Returns the write disposition.
|
BigQueryIO.Write.Bound |
named(String name)
Sets the name associated with this transformation.
|
BigQueryIO.Write.Bound |
to(SerializableFunction<BoundedWindow,String> tableSpecFunction) |
BigQueryIO.Write.Bound |
to(String tableSpec)
Specifies the table specification.
|
BigQueryIO.Write.Bound |
to(com.google.api.services.bigquery.model.TableReference table)
Specifies the table to be written to.
|
BigQueryIO.Write.Bound |
toTableReference(SerializableFunction<BoundedWindow,com.google.api.services.bigquery.model.TableReference> tableRefFunction) |
BigQueryIO.Write.Bound |
withCreateDisposition(BigQueryIO.Write.CreateDisposition createDisposition)
Specifies options for creating the table.
|
BigQueryIO.Write.Bound |
withoutValidation()
Disable table validation.
|
BigQueryIO.Write.Bound |
withSchema(com.google.api.services.bigquery.model.TableSchema schema)
Specifies the table schema, used if the table is created.
|
BigQueryIO.Write.Bound |
withWriteDisposition(BigQueryIO.Write.WriteDisposition writeDisposition)
Specifies options for writing the table.
|
getDefaultOutputCoder, getDefaultOutputCoder, getKindString, getName, toString, validatepublic BigQueryIO.Write.Bound named(String name)
public BigQueryIO.Write.Bound to(String tableSpec)
Refer to BigQueryIO.parseTableSpec(String) for the specification format.
public BigQueryIO.Write.Bound to(com.google.api.services.bigquery.model.TableReference table)
public BigQueryIO.Write.Bound to(SerializableFunction<BoundedWindow,String> tableSpecFunction)
public BigQueryIO.Write.Bound toTableReference(SerializableFunction<BoundedWindow,com.google.api.services.bigquery.model.TableReference> tableRefFunction)
public BigQueryIO.Write.Bound withSchema(com.google.api.services.bigquery.model.TableSchema schema)
public BigQueryIO.Write.Bound withCreateDisposition(BigQueryIO.Write.CreateDisposition createDisposition)
public BigQueryIO.Write.Bound withWriteDisposition(BigQueryIO.Write.WriteDisposition writeDisposition)
public BigQueryIO.Write.Bound withoutValidation()
public PDone apply(PCollection<com.google.api.services.bigquery.model.TableRow> input)
PTransformPTransform on the given InputT, and returns its
Output.
Composite transforms, which are defined in terms of other transforms, should return the output of one of the composed transforms. Non-composite transforms, which do not apply any transforms internally, should return a new unbound output and register evaluators (via backend-specific registration methods).
The default implementation throws an exception. A derived class must
either implement apply, or else each runner must supply a custom
implementation via
PipelineRunner.apply(com.google.cloud.dataflow.sdk.transforms.PTransform<InputT, OutputT>, InputT).
apply in class PTransform<PCollection<com.google.api.services.bigquery.model.TableRow>,PDone>protected Coder<Void> getDefaultOutputCoder()
PTransformCoder to use for the output of this
single-output PTransform.
By default, always throws
getDefaultOutputCoder in class PTransform<PCollection<com.google.api.services.bigquery.model.TableRow>,PDone>public BigQueryIO.Write.CreateDisposition getCreateDisposition()
public BigQueryIO.Write.WriteDisposition getWriteDisposition()
public com.google.api.services.bigquery.model.TableSchema getSchema()
public com.google.api.services.bigquery.model.TableReference getTable()
public boolean getValidate()