Class Table.Builder (2.43.3)

publicstaticclass Table.BuilderextendsTableInfo.Builder

A builder for Table objects.

Inheritance

java.lang.Object > TableInfo.Builder > Table.Builder

Inherited Members

Methods

build()

publicTablebuild()

Creates a TableInfo object.

Returns
Type Description
Table
Overrides

setCloneDefinition(CloneDefinition cloneDefinition)

publicTableInfo.BuildersetCloneDefinition(CloneDefinitioncloneDefinition)
Parameter
Name Description
cloneDefinition CloneDefinition
Returns
Type Description
TableInfo.Builder
Overrides

setDefaultCollation(String defaultCollation)

publicTable.BuildersetDefaultCollation(StringdefaultCollation)
Parameter
Name Description
defaultCollation String
Returns
Type Description
Table.Builder
Overrides

setDefinition(TableDefinition definition)

publicTable.BuildersetDefinition(TableDefinitiondefinition)

Sets the table definition. Use StandardTableDefinition to create simple BigQuery table. Use ViewDefinition to create a BigQuery view. Use ExternalTableDefinition to create a BigQuery a table backed by external data.

Parameter
Name Description
definition TableDefinition
Returns
Type Description
Table.Builder
Overrides

setDescription(String description)

publicTable.BuildersetDescription(Stringdescription)

Sets a user-friendly description for the table.

Parameter
Name Description
description String
Returns
Type Description
Table.Builder
Overrides

setEncryptionConfiguration(EncryptionConfiguration configuration)

publicTableInfo.BuildersetEncryptionConfiguration(EncryptionConfigurationconfiguration)
Parameter
Name Description
configuration EncryptionConfiguration
Returns
Type Description
TableInfo.Builder
Overrides

setExpirationTime(Long expirationTime)

publicTable.BuildersetExpirationTime(LongexpirationTime)

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.

Parameter
Name Description
expirationTime Long
Returns
Type Description
Table.Builder
Overrides

setFriendlyName(String friendlyName)

publicTable.BuildersetFriendlyName(StringfriendlyName)

Sets a user-friendly name for the table.

Parameter
Name Description
friendlyName String
Returns
Type Description
Table.Builder
Overrides

setLabels(Map<String,String> labels)

publicTable.BuildersetLabels(Map<String,String>labels)

Sets the labels applied to this table.

Unstable, because labels are experimental.

When used with BigQuery#update(TableInfo, TableOption...), setting labels to null removes all labels; otherwise all keys that are mapped to null values are removed and other keys are updated to their respective values.

Parameter
Name Description
labels Map<String,String>
Returns
Type Description
Table.Builder
Overrides

setRequirePartitionFilter(Boolean requirePartitionFilter)

publicTable.BuildersetRequirePartitionFilter(BooleanrequirePartitionFilter)
Parameter
Name Description
requirePartitionFilter Boolean
Returns
Type Description
Table.Builder
Overrides

setResourceTags(Map<String,String> resourceTags)

publicTable.BuildersetResourceTags(Map<String,String>resourceTags)

Sets the resource tags applied to this table.

Parameter
Name Description
resourceTags Map<String,String>
Returns
Type Description
Table.Builder
Overrides

setTableConstraints(TableConstraints tableConstraints)

publicTable.BuildersetTableConstraints(TableConstraintstableConstraints)
Parameter
Name Description
tableConstraints TableConstraints
Returns
Type Description
Table.Builder
Overrides

setTableId(TableId tableId)

publicTable.BuildersetTableId(TableIdtableId)

Sets the table identity.

Parameter
Name Description
tableId TableId
Returns
Type Description
Table.Builder
Overrides

Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2025年10月30日 UTC.