Class: Google::Apis::CloudfunctionsV2::Source

Inherits:
Object
  • Object
show all
Includes:
Google::Apis::Core::Hashable, Google::Apis::Core::JsonObjectSupport
Defined in:
lib/google/apis/cloudfunctions_v2/classes.rb,
lib/google/apis/cloudfunctions_v2/representations.rb,
lib/google/apis/cloudfunctions_v2/representations.rb

Overview

The location of the function source code.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ Source

Returns a new instance of Source.



2154
2155
2156
# File 'lib/google/apis/cloudfunctions_v2/classes.rb', line 2154

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

Instance Attribute Details

#git_uriString

If provided, get the source from GitHub repository. This option is valid only for GCF 1st Gen function. Example: https://github.com///blob// Corresponds to the JSON property gitUri

Returns:

  • (String)


2142
2143
2144
# File 'lib/google/apis/cloudfunctions_v2/classes.rb', line 2142

def git_uri
  @git_uri
end

#repo_sourceGoogle::Apis::CloudfunctionsV2::RepoSource

Location of the source in a Google Cloud Source Repository. Corresponds to the JSON property repoSource



2147
2148
2149
# File 'lib/google/apis/cloudfunctions_v2/classes.rb', line 2147

def repo_source
  @repo_source
end

#storage_sourceGoogle::Apis::CloudfunctionsV2::StorageSource

Location of the source in an archive file in Google Cloud Storage. Corresponds to the JSON property storageSource



2152
2153
2154
# File 'lib/google/apis/cloudfunctions_v2/classes.rb', line 2152

def storage_source
  @storage_source
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



2159
2160
2161
2162
2163
# File 'lib/google/apis/cloudfunctions_v2/classes.rb', line 2159

def update!(**args)
  @git_uri = args[:git_uri] if args.key?(:git_uri)
  @repo_source = args[:repo_source] if args.key?(:repo_source)
  @storage_source = args[:storage_source] if args.key?(:storage_source)
end