Class: Google::Apis::BigqueryV2::TableConstraints::ForeignKey
- Inherits:
-
Object
- Object
- Google::Apis::BigqueryV2::TableConstraints::ForeignKey
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/bigquery_v2/classes.rb,
lib/google/apis/bigquery_v2/representations.rb,
lib/google/apis/bigquery_v2/representations.rb
Overview
Represents a foreign key constraint on a table's columns.
Defined Under Namespace
Classes: ColumnReference, ReferencedTable
Instance Attribute Summary collapse
-
#column_references ⇒ Array<Google::Apis::BigqueryV2::TableConstraints::ForeignKey::ColumnReference>
Required.
-
#name ⇒ String
Optional.
-
#referenced_table ⇒ Google::Apis::BigqueryV2::TableConstraints::ForeignKey::ReferencedTable
Corresponds to the JSON property
referencedTable.
Instance Method Summary collapse
-
#initialize(**args) ⇒ ForeignKey
constructor
A new instance of ForeignKey.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ ForeignKey
Returns a new instance of ForeignKey.
10429 10430 10431 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 10429 def initialize(**args) update!(**args) end |
Instance Attribute Details
#column_references ⇒ Array<Google::Apis::BigqueryV2::TableConstraints::ForeignKey::ColumnReference>
Required. The columns that compose the foreign key.
Corresponds to the JSON property columnReferences
10417 10418 10419 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 10417 def column_references @column_references end |
#name ⇒ String
Optional. Set only if the foreign key constraint is named.
Corresponds to the JSON property name
10422 10423 10424 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 10422 def name @name end |
#referenced_table ⇒ Google::Apis::BigqueryV2::TableConstraints::ForeignKey::ReferencedTable
Corresponds to the JSON property referencedTable
10427 10428 10429 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 10427 def referenced_table @referenced_table end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
10434 10435 10436 10437 10438 |
# File 'lib/google/apis/bigquery_v2/classes.rb', line 10434 def update!(**args) @column_references = args[:column_references] if args.key?(:column_references) @name = args[:name] if args.key?(:name) @referenced_table = args[:referenced_table] if args.key?(:referenced_table) end |