Class: Google::Apis::BigqueryV2::Argument

Inherits:
Object
  • Object
show all
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

Input/output argument of a function or a stored procedure.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ Argument

Returns a new instance of Argument.



161
162
163
# File 'lib/google/apis/bigquery_v2/classes.rb', line 161

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#argument_kindString

Optional. Defaults to FIXED_TYPE. Corresponds to the JSON property argumentKind

Returns:

  • (String)


127
128
129
# File 'lib/google/apis/bigquery_v2/classes.rb', line 127

def argument_kind
  @argument_kind
end

#data_typeGoogle::Apis::BigqueryV2::StandardSqlDataType

The data type of a variable such as a function argument. Examples include: * INT64: "typeKind": "INT64" * ARRAY: "typeKind": "ARRAY", " arrayElementType":"typeKind": "STRING" * STRUCT>: "typeKind": "STRUCT", "structType": "fields": [ "name": "x", "type":"typeKind": "STRING", "name": "y", "type": "typeKind": "ARRAY", "arrayElementType": "typeKind": " DATE" ] * RANGE: "typeKind": "RANGE", "rangeElementType":" typeKind": "DATE" Corresponds to the JSON property dataType



138
139
140
# File 'lib/google/apis/bigquery_v2/classes.rb', line 138

def data_type
  @data_type
end

#is_aggregateBoolean Also known as: is_aggregate?

Optional. Whether the argument is an aggregate function parameter. Must be Unset for routine types other than AGGREGATE_FUNCTION. For AGGREGATE_FUNCTION, if set to false, it is equivalent to adding "NOT AGGREGATE" clause in DDL; Otherwise, it is equivalent to omitting "NOT AGGREGATE" clause in DDL. Corresponds to the JSON property isAggregate

Returns:

  • (Boolean)


146
147
148
# File 'lib/google/apis/bigquery_v2/classes.rb', line 146

def is_aggregate
  @is_aggregate
end

#modeString

Optional. Specifies whether the argument is input or output. Can be set for procedures only. Corresponds to the JSON property mode

Returns:

  • (String)


153
154
155
# File 'lib/google/apis/bigquery_v2/classes.rb', line 153

def mode
  @mode
end

#nameString

Optional. The name of this argument. Can be absent for function return argument. Corresponds to the JSON property name

Returns:

  • (String)


159
160
161
# File 'lib/google/apis/bigquery_v2/classes.rb', line 159

def name
  @name
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



166
167
168
169
170
171
172
# File 'lib/google/apis/bigquery_v2/classes.rb', line 166

def update!(**args)
  @argument_kind = args[:argument_kind] if args.key?(:argument_kind)
  @data_type = args[:data_type] if args.key?(:data_type)
  @is_aggregate = args[:is_aggregate] if args.key?(:is_aggregate)
  @mode = args[:mode] if args.key?(:mode)
  @name = args[:name] if args.key?(:name)
end