Class: Google::Cloud::Spanner::V1::StructType

Inherits:
Object
  • Object
show all
Extended by:
Protobuf::MessageExts::ClassMethods
Includes:
Protobuf::MessageExts
Defined in:
proto_docs/google/spanner/v1/type.rb

Overview

StructType defines the fields of a STRUCT type.

Defined Under Namespace

Classes: Field

Instance Attribute Summary collapse

Instance Attribute Details

#fields::Array<::Google::Cloud::Spanner::V1::StructType::Field>

Returns The list of fields that make up this struct. Order is significant, because values of this struct type are represented as lists, where the order of field values matches the order of fields in the StructType. In turn, the order of fields matches the order of columns in a read request, or the order of fields in the SELECT clause of a query.

Returns:

  • (::Array<::Google::Cloud::Spanner::V1::StructType::Field>)

    The list of fields that make up this struct. Order is significant, because values of this struct type are represented as lists, where the order of field values matches the order of fields in the StructType. In turn, the order of fields matches the order of columns in a read request, or the order of fields in the SELECT clause of a query.



71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
# File 'proto_docs/google/spanner/v1/type.rb', line 71

class StructType
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Message representing a single field of a struct.
  # @!attribute [rw] name
  #   @return [::String]
  #     The name of the field. For reads, this is the column name. For
  #     SQL queries, it is the column alias (e.g., `"Word"` in the
  #     query `"SELECT 'hello' AS Word"`), or the column name (e.g.,
  #     `"ColName"` in the query `"SELECT ColName FROM Table"`). Some
  #     columns might have an empty name (e.g., `"SELECT
  #     UPPER(ColName)"`). Note that a query result can contain
  #     multiple fields with the same name.
  # @!attribute [rw] type
  #   @return [::Google::Cloud::Spanner::V1::Type]
  #     The type of the field.
  class Field
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end
end