Package com.google.cloud.bigquery
Class TableInfo.Builder
- java.lang.Object
-
- com.google.cloud.bigquery.TableInfo.Builder
-
- Direct Known Subclasses:
Table.Builder
- Enclosing class:
- TableInfo
public abstract static class TableInfo.Builder extends Object
A builder forTableInfo
objects.
-
-
Constructor Summary
Constructors Constructor Description Builder()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract TableInfo
build()
Creates aTableInfo
object.abstract TableInfo.Builder
setCloneDefinition(CloneDefinition cloneDefinition)
abstract TableInfo.Builder
setDefaultCollation(String defaultCollation)
abstract TableInfo.Builder
setDefinition(TableDefinition definition)
Sets the table definition.abstract TableInfo.Builder
setDescription(String description)
Sets a user-friendly description for the table.abstract TableInfo.Builder
setEncryptionConfiguration(EncryptionConfiguration configuration)
abstract TableInfo.Builder
setExpirationTime(Long expirationTime)
Sets the time when this table expires, in milliseconds since the epoch.abstract TableInfo.Builder
setFriendlyName(String friendlyName)
Sets a user-friendly name for the table.abstract TableInfo.Builder
setLabels(Map<String,String> labels)
Sets the labels applied to this table.TableInfo.Builder
setRequirePartitionFilter(Boolean requirePartitionFilter)
abstract TableInfo.Builder
setTableConstraints(TableConstraints tableConstraints)
abstract TableInfo.Builder
setTableId(TableId tableId)
Sets the table identity.
-
-
-
Method Detail
-
setDescription
public abstract TableInfo.Builder setDescription(String description)
Sets a user-friendly description for the table.
-
setExpirationTime
public abstract TableInfo.Builder setExpirationTime(Long expirationTime)
Sets the time when this table expires, in milliseconds since the epoch. If not present, the table will persist indefinitely. Expired tables will be deleted and their storage reclaimed.
-
setFriendlyName
public abstract TableInfo.Builder setFriendlyName(String friendlyName)
Sets a user-friendly name for the table.
-
setTableId
public abstract TableInfo.Builder setTableId(TableId tableId)
Sets the table identity.
-
setDefinition
public abstract TableInfo.Builder setDefinition(TableDefinition definition)
Sets the table definition. UseStandardTableDefinition
to create simple BigQuery table. UseViewDefinition
to create a BigQuery view. UseExternalTableDefinition
to create a BigQuery a table backed by external data.
-
setLabels
@BetaApi public abstract TableInfo.Builder setLabels(Map<String,String> labels)
Sets the labels applied to this table.Unstable, because labels are experimental.
When used with
BigQuery.update(TableInfo, TableOption...)
, settinglabels
tonull
removes all labels; otherwise all keys that are mapped tonull
values are removed and other keys are updated to their respective values.
-
build
public abstract TableInfo build()
Creates aTableInfo
object.
-
setEncryptionConfiguration
public abstract TableInfo.Builder setEncryptionConfiguration(EncryptionConfiguration configuration)
-
setRequirePartitionFilter
public TableInfo.Builder setRequirePartitionFilter(Boolean requirePartitionFilter)
-
setDefaultCollation
public abstract TableInfo.Builder setDefaultCollation(String defaultCollation)
-
setCloneDefinition
public abstract TableInfo.Builder setCloneDefinition(CloneDefinition cloneDefinition)
-
setTableConstraints
public abstract TableInfo.Builder setTableConstraints(TableConstraints tableConstraints)
-
-