Class: Google::Apis::CloudbuildV2::Connection

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

Overview

A connection to a SCM like GitHub, GitHub Enterprise, Bitbucket Data Center or GitLab.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ Connection

Returns a new instance of Connection.



379
380
381
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 379

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

Instance Attribute Details

#annotationsHash<String,String>

Allows clients to store small amounts of arbitrary data. Corresponds to the JSON property annotations

Returns:

  • (Hash<String,String>)


317
318
319
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 317

def annotations
  @annotations
end

#create_timeString

Output only. Server assigned timestamp for when the connection was created. Corresponds to the JSON property createTime

Returns:

  • (String)


322
323
324
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 322

def create_time
  @create_time
end

#disabledBoolean Also known as: disabled?

If disabled is set to true, functionality is disabled for this connection. Repository based API methods and webhooks processing for repositories in this connection will be disabled. Corresponds to the JSON property disabled

Returns:

  • (Boolean)


329
330
331
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 329

def disabled
  @disabled
end

#etagString

This checksum is computed by the server based on the value of other fields, and may be sent on update and delete requests to ensure the client has an up- to-date value before proceeding. Corresponds to the JSON property etag

Returns:

  • (String)


337
338
339
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 337

def etag
  @etag
end

#github_configGoogle::Apis::CloudbuildV2::GitHubConfig

Configuration for connections to github.com. Corresponds to the JSON property githubConfig



342
343
344
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 342

def github_config
  @github_config
end

#github_enterprise_configGoogle::Apis::CloudbuildV2::GoogleDevtoolsCloudbuildV2GitHubEnterpriseConfig

Configuration for connections to an instance of GitHub Enterprise. Corresponds to the JSON property githubEnterpriseConfig



347
348
349
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 347

def github_enterprise_config
  @github_enterprise_config
end

#gitlab_configGoogle::Apis::CloudbuildV2::GoogleDevtoolsCloudbuildV2GitLabConfig

Configuration for connections to gitlab.com or an instance of GitLab Enterprise. Corresponds to the JSON property gitlabConfig



353
354
355
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 353

def gitlab_config
  @gitlab_config
end

#installation_stateGoogle::Apis::CloudbuildV2::InstallationState

Describes stage and necessary actions to be taken by the user to complete the installation. Used for GitHub and GitHub Enterprise based connections. Corresponds to the JSON property installationState



359
360
361
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 359

def installation_state
  @installation_state
end

#nameString

Immutable. The resource name of the connection, in the format projects/ project/locations/location/connections/connection_id`. Corresponds to the JSON propertyname`

Returns:

  • (String)


365
366
367
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 365

def name
  @name
end

#reconcilingBoolean Also known as: reconciling?

Output only. Set to true when the connection is being set up or updated in the background. Corresponds to the JSON property reconciling

Returns:

  • (Boolean)


371
372
373
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 371

def reconciling
  @reconciling
end

#update_timeString

Output only. Server assigned timestamp for when the connection was updated. Corresponds to the JSON property updateTime

Returns:

  • (String)


377
378
379
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 377

def update_time
  @update_time
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



384
385
386
387
388
389
390
391
392
393
394
395
396
# File 'lib/google/apis/cloudbuild_v2/classes.rb', line 384

def update!(**args)
  @annotations = args[:annotations] if args.key?(:annotations)
  @create_time = args[:create_time] if args.key?(:create_time)
  @disabled = args[:disabled] if args.key?(:disabled)
  @etag = args[:etag] if args.key?(:etag)
  @github_config = args[:github_config] if args.key?(:github_config)
  @github_enterprise_config = args[:github_enterprise_config] if args.key?(:github_enterprise_config)
  @gitlab_config = args[:gitlab_config] if args.key?(:gitlab_config)
  @installation_state = args[:installation_state] if args.key?(:installation_state)
  @name = args[:name] if args.key?(:name)
  @reconciling = args[:reconciling] if args.key?(:reconciling)
  @update_time = args[:update_time] if args.key?(:update_time)
end