Class: Google::Apis::BigqueryV2::PythonOptions

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

Options for a user-defined Python function.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ PythonOptions

Returns a new instance of PythonOptions.



7808
7809
7810
# File 'lib/google/apis/bigquery_v2/classes.rb', line 7808

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

Instance Attribute Details

#entry_pointString

Required. The name of the function defined in Python code as the entry point when the Python UDF is invoked. Corresponds to the JSON property entryPoint

Returns:

  • (String)


7798
7799
7800
# File 'lib/google/apis/bigquery_v2/classes.rb', line 7798

def entry_point
  @entry_point
end

#packagesArray<String>

Optional. A list of Python package names along with versions to be installed. Example: ["pandas>=2.1", "google-cloud-translate==3.11"]. For more information, see Use third-party packages. Corresponds to the JSON property packages

Returns:

  • (Array<String>)


7806
7807
7808
# File 'lib/google/apis/bigquery_v2/classes.rb', line 7806

def packages
  @packages
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



7813
7814
7815
7816
# File 'lib/google/apis/bigquery_v2/classes.rb', line 7813

def update!(**args)
  @entry_point = args[:entry_point] if args.key?(:entry_point)
  @packages = args[:packages] if args.key?(:packages)
end