Class: Google::Apis::CloudkmsV1::GenerateRandomBytesRequest

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

Request message for KeyManagementService.GenerateRandomBytes.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GenerateRandomBytesRequest

Returns a new instance of GenerateRandomBytesRequest.



1022
1023
1024
# File 'lib/google/apis/cloudkms_v1/classes.rb', line 1022

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

Instance Attribute Details

#length_bytesFixnum

The length in bytes of the amount of randomness to retrieve. Minimum 8 bytes, maximum 1024 bytes. Corresponds to the JSON property lengthBytes

Returns:

  • (Fixnum)


1014
1015
1016
# File 'lib/google/apis/cloudkms_v1/classes.rb', line 1014

def length_bytes
  @length_bytes
end

#protection_levelString

The ProtectionLevel to use when generating the random data. Defaults to SOFTWARE. Corresponds to the JSON property protectionLevel

Returns:

  • (String)


1020
1021
1022
# File 'lib/google/apis/cloudkms_v1/classes.rb', line 1020

def protection_level
  @protection_level
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1027
1028
1029
1030
# File 'lib/google/apis/cloudkms_v1/classes.rb', line 1027

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