Class: OCI::Rover::Models::RoverNodeReplaceCertificateAuthorityDetails
- Inherits:
-
Object
- Object
- OCI::Rover::Models::RoverNodeReplaceCertificateAuthorityDetails
- Defined in:
- lib/oci/rover/models/rover_node_replace_certificate_authority_details.rb
Overview
The information required to replace a certificate authority details for a roverNode.
Constant Summary collapse
- CERT_KEY_ALGORITHM_ENUM =
[ CERT_KEY_ALGORITHM_RSA2048 = 'RSA2048'.freeze, CERT_KEY_ALGORITHM_RSA4096 = 'RSA4096'.freeze, CERT_KEY_ALGORITHM_ECDSA_P256 = 'ECDSA_P256'.freeze, CERT_KEY_ALGORITHM_ECDSA_P384 = 'ECDSA_P384'.freeze ].freeze
- CERT_SIGNATURE_ALGORITHM_ENUM =
[ CERT_SIGNATURE_ALGORITHM_SHA256_WITH_RSA = 'SHA256_WITH_RSA'.freeze, CERT_SIGNATURE_ALGORITHM_SHA384_WITH_RSA = 'SHA384_WITH_RSA'.freeze, CERT_SIGNATURE_ALGORITHM_SHA512_WITH_RSA = 'SHA512_WITH_RSA'.freeze, CERT_SIGNATURE_ALGORITHM_SHA256_WITH_ECDSA = 'SHA256_WITH_ECDSA'.freeze, CERT_SIGNATURE_ALGORITHM_SHA384_WITH_ECDSA = 'SHA384_WITH_ECDSA'.freeze, CERT_SIGNATURE_ALGORITHM_SHA512_WITH_ECDSA = 'SHA512_WITH_ECDSA'.freeze ].freeze
Instance Attribute Summary collapse
-
#cert_key_algorithm ⇒ String
key algorithm for issuing leaf certificate.
-
#cert_signature_algorithm ⇒ String
signature algorithm for issuing leaf certificate.
-
#certificate_authority_id ⇒ String
[Required] The certificate authority id.
Class Method Summary collapse
-
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
-
.swagger_types ⇒ Object
Attribute type mapping.
Instance Method Summary collapse
-
#==(other) ⇒ Object
Checks equality by comparing each attribute.
-
#build_from_hash(attributes) ⇒ Object
Builds the object from hash.
- #eql?(other) ⇒ Boolean
-
#hash ⇒ Fixnum
Calculates hash code according to all attributes.
-
#initialize(attributes = {}) ⇒ RoverNodeReplaceCertificateAuthorityDetails
constructor
Initializes the object.
-
#to_hash ⇒ Hash
Returns the object in the form of hash.
-
#to_s ⇒ String
Returns the string representation of the object.
Constructor Details
#initialize(attributes = {}) ⇒ RoverNodeReplaceCertificateAuthorityDetails
Initializes the object
70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 |
# File 'lib/oci/rover/models/rover_node_replace_certificate_authority_details.rb', line 70 def initialize(attributes = {}) return unless attributes.is_a?(Hash) # convert string to symbol for hash key attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v } self. = attributes[:'certificateAuthorityId'] if attributes[:'certificateAuthorityId'] raise 'You cannot provide both :certificateAuthorityId and :certificate_authority_id' if attributes.key?(:'certificateAuthorityId') && attributes.key?(:'certificate_authority_id') self. = attributes[:'certificate_authority_id'] if attributes[:'certificate_authority_id'] self.cert_key_algorithm = attributes[:'certKeyAlgorithm'] if attributes[:'certKeyAlgorithm'] raise 'You cannot provide both :certKeyAlgorithm and :cert_key_algorithm' if attributes.key?(:'certKeyAlgorithm') && attributes.key?(:'cert_key_algorithm') self.cert_key_algorithm = attributes[:'cert_key_algorithm'] if attributes[:'cert_key_algorithm'] self.cert_signature_algorithm = attributes[:'certSignatureAlgorithm'] if attributes[:'certSignatureAlgorithm'] raise 'You cannot provide both :certSignatureAlgorithm and :cert_signature_algorithm' if attributes.key?(:'certSignatureAlgorithm') && attributes.key?(:'cert_signature_algorithm') self.cert_signature_algorithm = attributes[:'cert_signature_algorithm'] if attributes[:'cert_signature_algorithm'] end |
Instance Attribute Details
#cert_key_algorithm ⇒ String
key algorithm for issuing leaf certificate.
33 34 35 |
# File 'lib/oci/rover/models/rover_node_replace_certificate_authority_details.rb', line 33 def cert_key_algorithm @cert_key_algorithm end |
#cert_signature_algorithm ⇒ String
signature algorithm for issuing leaf certificate.
37 38 39 |
# File 'lib/oci/rover/models/rover_node_replace_certificate_authority_details.rb', line 37 def cert_signature_algorithm @cert_signature_algorithm end |
#certificate_authority_id ⇒ String
[Required] The certificate authority id.
29 30 31 |
# File 'lib/oci/rover/models/rover_node_replace_certificate_authority_details.rb', line 29 def @certificate_authority_id end |
Class Method Details
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
40 41 42 43 44 45 46 47 48 |
# File 'lib/oci/rover/models/rover_node_replace_certificate_authority_details.rb', line 40 def self.attribute_map { # rubocop:disable Style/SymbolLiteral 'certificate_authority_id': :'certificateAuthorityId', 'cert_key_algorithm': :'certKeyAlgorithm', 'cert_signature_algorithm': :'certSignatureAlgorithm' # rubocop:enable Style/SymbolLiteral } end |
.swagger_types ⇒ Object
Attribute type mapping.
51 52 53 54 55 56 57 58 59 |
# File 'lib/oci/rover/models/rover_node_replace_certificate_authority_details.rb', line 51 def self.swagger_types { # rubocop:disable Style/SymbolLiteral 'certificate_authority_id': :'String', 'cert_key_algorithm': :'String', 'cert_signature_algorithm': :'String' # rubocop:enable Style/SymbolLiteral } end |
Instance Method Details
#==(other) ⇒ Object
Checks equality by comparing each attribute.
118 119 120 121 122 123 124 125 |
# File 'lib/oci/rover/models/rover_node_replace_certificate_authority_details.rb', line 118 def ==(other) return true if equal?(other) self.class == other.class && == other. && cert_key_algorithm == other.cert_key_algorithm && cert_signature_algorithm == other.cert_signature_algorithm end |
#build_from_hash(attributes) ⇒ Object
Builds the object from hash
150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 |
# File 'lib/oci/rover/models/rover_node_replace_certificate_authority_details.rb', line 150 def build_from_hash(attributes) return nil unless attributes.is_a?(Hash) self.class.swagger_types.each_pair do |key, type| if type =~ /^Array<(.*)>/i # check to ensure the input is an array given that the the attribute # is documented as an array but the input is not if attributes[self.class.attribute_map[key]].is_a?(Array) public_method("#{key}=").call( attributes[self.class.attribute_map[key]] .map { |v| OCI::Internal::Util.convert_to_type(Regexp.last_match(1), v) } ) end elsif !attributes[self.class.attribute_map[key]].nil? public_method("#{key}=").call( OCI::Internal::Util.convert_to_type(type, attributes[self.class.attribute_map[key]]) ) end # or else data not found in attributes(hash), not an issue as the data can be optional end self end |
#eql?(other) ⇒ Boolean
130 131 132 |
# File 'lib/oci/rover/models/rover_node_replace_certificate_authority_details.rb', line 130 def eql?(other) self == other end |
#hash ⇒ Fixnum
Calculates hash code according to all attributes.
139 140 141 |
# File 'lib/oci/rover/models/rover_node_replace_certificate_authority_details.rb', line 139 def hash [, cert_key_algorithm, cert_signature_algorithm].hash end |
#to_hash ⇒ Hash
Returns the object in the form of hash
183 184 185 186 187 188 189 190 191 192 |
# File 'lib/oci/rover/models/rover_node_replace_certificate_authority_details.rb', line 183 def to_hash hash = {} self.class.attribute_map.each_pair do |attr, param| value = public_method(attr).call next if value.nil? && !instance_variable_defined?("@#{attr}") hash[param] = _to_hash(value) end hash end |
#to_s ⇒ String
Returns the string representation of the object
177 178 179 |
# File 'lib/oci/rover/models/rover_node_replace_certificate_authority_details.rb', line 177 def to_s to_hash.to_s end |