Class: Google::Apis::DatastreamV1::SpannerColumn
- Inherits:
-
Object
- Object
- Google::Apis::DatastreamV1::SpannerColumn
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/datastream_v1/classes.rb,
lib/google/apis/datastream_v1/representations.rb,
lib/google/apis/datastream_v1/representations.rb
Overview
Spanner column.
Instance Attribute Summary collapse
-
#column ⇒ String
Required.
-
#data_type ⇒ String
Optional.
-
#is_primary_key ⇒ Boolean
(also: #is_primary_key?)
Optional.
-
#ordinal_position ⇒ Fixnum
Optional.
Instance Method Summary collapse
-
#initialize(**args) ⇒ SpannerColumn
constructor
A new instance of SpannerColumn.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ SpannerColumn
Returns a new instance of SpannerColumn.
4304 4305 4306 |
# File 'lib/google/apis/datastream_v1/classes.rb', line 4304 def initialize(**args) update!(**args) end |
Instance Attribute Details
#column ⇒ String
Required. The column name.
Corresponds to the JSON property column
4286 4287 4288 |
# File 'lib/google/apis/datastream_v1/classes.rb', line 4286 def column @column end |
#data_type ⇒ String
Optional. Spanner data type.
Corresponds to the JSON property dataType
4291 4292 4293 |
# File 'lib/google/apis/datastream_v1/classes.rb', line 4291 def data_type @data_type end |
#is_primary_key ⇒ Boolean Also known as: is_primary_key?
Optional. Whether or not the column is a primary key.
Corresponds to the JSON property isPrimaryKey
4296 4297 4298 |
# File 'lib/google/apis/datastream_v1/classes.rb', line 4296 def is_primary_key @is_primary_key end |
#ordinal_position ⇒ Fixnum
Optional. The ordinal position of the column in the table.
Corresponds to the JSON property ordinalPosition
4302 4303 4304 |
# File 'lib/google/apis/datastream_v1/classes.rb', line 4302 def ordinal_position @ordinal_position end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
4309 4310 4311 4312 4313 4314 |
# File 'lib/google/apis/datastream_v1/classes.rb', line 4309 def update!(**args) @column = args[:column] if args.key?(:column) @data_type = args[:data_type] if args.key?(:data_type) @is_primary_key = args[:is_primary_key] if args.key?(:is_primary_key) @ordinal_position = args[:ordinal_position] if args.key?(:ordinal_position) end |