Class: OCI::IdentityDomains::Models::UserExtRiskScores
- Inherits:
-
Object
- Object
- OCI::IdentityDomains::Models::UserExtRiskScores
- Defined in:
- lib/oci/identity_domains/models/user_ext_risk_scores.rb
Overview
The risk score pertaining to the user.
Added In: 18.1.6
SCIM++ Properties: - caseExact: false - idcsCompositeKey: [value] - multiValued: true - mutability: readWrite - required: false - returned: request - type: complex - uniqueness: none
Constant Summary collapse
- RISK_LEVEL_ENUM =
[ RISK_LEVEL_LOW = 'LOW'.freeze, RISK_LEVEL_MEDIUM = 'MEDIUM'.freeze, RISK_LEVEL_HIGH = 'HIGH'.freeze, RISK_LEVEL_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze ].freeze
Instance Attribute Summary collapse
-
#last_update_timestamp ⇒ String
[Required] Last update timestamp for the risk score.
-
#ref ⇒ String
Risk Provider Profile URI: URI that corresponds to risk source identifier.
-
#risk_level ⇒ String
[Required] Risk Level.
-
#score ⇒ Integer
[Required] Risk Score value.
-
#source ⇒ String
Risk Provider Profile Source.
-
#status ⇒ String
Risk Provider Profile status.
-
#value ⇒ String
[Required] Risk Provider Profile: Identifier for the provider service from which the risk score was received.
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 = {}) ⇒ UserExtRiskScores
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 = {}) ⇒ UserExtRiskScores
Initializes the object
187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 |
# File 'lib/oci/identity_domains/models/user_ext_risk_scores.rb', line 187 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.value = attributes[:'value'] if attributes[:'value'] self.ref = attributes[:'$ref'] if attributes[:'$ref'] self.source = attributes[:'source'] if attributes[:'source'] self.status = attributes[:'status'] if attributes[:'status'] self.score = attributes[:'score'] if attributes[:'score'] self.risk_level = attributes[:'riskLevel'] if attributes[:'riskLevel'] raise 'You cannot provide both :riskLevel and :risk_level' if attributes.key?(:'riskLevel') && attributes.key?(:'risk_level') self.risk_level = attributes[:'risk_level'] if attributes[:'risk_level'] self. = attributes[:'lastUpdateTimestamp'] if attributes[:'lastUpdateTimestamp'] raise 'You cannot provide both :lastUpdateTimestamp and :last_update_timestamp' if attributes.key?(:'lastUpdateTimestamp') && attributes.key?(:'last_update_timestamp') self. = attributes[:'last_update_timestamp'] if attributes[:'last_update_timestamp'] end |
Instance Attribute Details
#last_update_timestamp ⇒ String
[Required] Last update timestamp for the risk score
Added In: 18.1.6
SCIM++ Properties: - caseExact: false - idcsSearchable: false - multiValued: false - mutability: readWrite - required: true - returned: always - type: dateTime - uniqueness: none
142 143 144 |
# File 'lib/oci/identity_domains/models/user_ext_risk_scores.rb', line 142 def @last_update_timestamp end |
#ref ⇒ String
Risk Provider Profile URI: URI that corresponds to risk source identifier.
Added In: 18.1.6
SCIM++ Properties: - caseExact: true - idcsSearchable: false - multiValued: false - mutability: readOnly - required: false - returned: always - type: reference - uniqueness: none
61 62 63 |
# File 'lib/oci/identity_domains/models/user_ext_risk_scores.rb', line 61 def ref @ref end |
#risk_level ⇒ String
[Required] Risk Level
Added In: 18.1.6
SCIM++ Properties: - idcsSearchable: true - multiValued: false - mutability: readWrite - required: true - returned: always - type: string - uniqueness: none
126 127 128 |
# File 'lib/oci/identity_domains/models/user_ext_risk_scores.rb', line 126 def risk_level @risk_level end |
#score ⇒ Integer
[Required] Risk Score value
Added In: 18.1.6
SCIM++ Properties: - caseExact: false - idcsSearchable: true - multiValued: false - mutability: readWrite - required: true - returned: always - type: integer - uniqueness: none - idcsMaxValue: 100 - idcsMinValue: 0
111 112 113 |
# File 'lib/oci/identity_domains/models/user_ext_risk_scores.rb', line 111 def score @score end |
#source ⇒ String
Risk Provider Profile Source
Added In: 18.1.6
SCIM++ Properties: - caseExact: false - idcsSearchable: true - multiValued: false - mutability: readOnly - required: false - returned: always - type: string - uniqueness: none
77 78 79 |
# File 'lib/oci/identity_domains/models/user_ext_risk_scores.rb', line 77 def source @source end |
#status ⇒ String
Risk Provider Profile status
Added In: 18.1.6
SCIM++ Properties: - caseExact: false - idcsSearchable: true - multiValued: false - mutability: readOnly - required: false - returned: always - type: string - uniqueness: none
93 94 95 |
# File 'lib/oci/identity_domains/models/user_ext_risk_scores.rb', line 93 def status @status end |
#value ⇒ String
[Required] Risk Provider Profile: Identifier for the provider service from which the risk score was received.
Added In: 18.1.6
SCIM++ Properties: - caseExact: true - idcsSearchable: true - multiValued: false - mutability: readWrite - required: true - returned: always - type: string - uniqueness: none
45 46 47 |
# File 'lib/oci/identity_domains/models/user_ext_risk_scores.rb', line 45 def value @value end |
Class Method Details
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
145 146 147 148 149 150 151 152 153 154 155 156 157 |
# File 'lib/oci/identity_domains/models/user_ext_risk_scores.rb', line 145 def self.attribute_map { # rubocop:disable Style/SymbolLiteral 'value': :'value', 'ref': :'$ref', 'source': :'source', 'status': :'status', 'score': :'score', 'risk_level': :'riskLevel', 'last_update_timestamp': :'lastUpdateTimestamp' # rubocop:enable Style/SymbolLiteral } end |
.swagger_types ⇒ Object
Attribute type mapping.
160 161 162 163 164 165 166 167 168 169 170 171 172 |
# File 'lib/oci/identity_domains/models/user_ext_risk_scores.rb', line 160 def self.swagger_types { # rubocop:disable Style/SymbolLiteral 'value': :'String', 'ref': :'String', 'source': :'String', 'status': :'String', 'score': :'Integer', 'risk_level': :'String', 'last_update_timestamp': :'String' # rubocop:enable Style/SymbolLiteral } end |
Instance Method Details
#==(other) ⇒ Object
Checks equality by comparing each attribute.
236 237 238 239 240 241 242 243 244 245 246 247 |
# File 'lib/oci/identity_domains/models/user_ext_risk_scores.rb', line 236 def ==(other) return true if equal?(other) self.class == other.class && value == other.value && ref == other.ref && source == other.source && status == other.status && score == other.score && risk_level == other.risk_level && == other. end |
#build_from_hash(attributes) ⇒ Object
Builds the object from hash
272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 |
# File 'lib/oci/identity_domains/models/user_ext_risk_scores.rb', line 272 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
252 253 254 |
# File 'lib/oci/identity_domains/models/user_ext_risk_scores.rb', line 252 def eql?(other) self == other end |
#hash ⇒ Fixnum
Calculates hash code according to all attributes.
261 262 263 |
# File 'lib/oci/identity_domains/models/user_ext_risk_scores.rb', line 261 def hash [value, ref, source, status, score, risk_level, ].hash end |
#to_hash ⇒ Hash
Returns the object in the form of hash
305 306 307 308 309 310 311 312 313 314 |
# File 'lib/oci/identity_domains/models/user_ext_risk_scores.rb', line 305 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
299 300 301 |
# File 'lib/oci/identity_domains/models/user_ext_risk_scores.rb', line 299 def to_s to_hash.to_s end |