Class: Google::Apis::CloudkmsV1::KeyHandle

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

Overview

Resource-oriented representation of a request to Cloud KMS Autokey and the resulting provisioning of a CryptoKey.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ KeyHandle

Returns a new instance of KeyHandle.



1587
1588
1589
# File 'lib/google/apis/cloudkms_v1/classes.rb', line 1587

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

Instance Attribute Details

#kms_keyString

Output only. Name of a CryptoKey that has been provisioned for Customer Managed Encryption Key (CMEK) use in the KeyHandle project and location for the requested resource type. The CryptoKey project will reflect the value configured in the AutokeyConfig on the resource project's ancestor folder at the time of the KeyHandle creation. If more than one ancestor folder has a configured AutokeyConfig, the nearest of these configurations is used. Corresponds to the JSON property kmsKey

Returns:

  • (String)


1572
1573
1574
# File 'lib/google/apis/cloudkms_v1/classes.rb', line 1572

def kms_key
  @kms_key
end

#nameString

Identifier. Name of the KeyHandle resource, e.g. projects/PROJECT_ID/ locations/LOCATION/keyHandles/KEY_HANDLE_ID`. Corresponds to the JSON propertyname`

Returns:

  • (String)


1578
1579
1580
# File 'lib/google/apis/cloudkms_v1/classes.rb', line 1578

def name
  @name
end

#resource_type_selectorString

Required. Indicates the resource type that the resulting CryptoKey is meant to protect, e.g. SERVICE`.googleapis.com/`TYPE. See documentation for supported resource types. Corresponds to the JSON property resourceTypeSelector

Returns:

  • (String)


1585
1586
1587
# File 'lib/google/apis/cloudkms_v1/classes.rb', line 1585

def resource_type_selector
  @resource_type_selector
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1592
1593
1594
1595
1596
# File 'lib/google/apis/cloudkms_v1/classes.rb', line 1592

def update!(**args)
  @kms_key = args[:kms_key] if args.key?(:kms_key)
  @name = args[:name] if args.key?(:name)
  @resource_type_selector = args[:resource_type_selector] if args.key?(:resource_type_selector)
end