Class: OCI::DataSafe::Models::ProfileSummary
- Inherits:
-
Object
- Object
- OCI::DataSafe::Models::ProfileSummary
- Defined in:
- lib/oci/data_safe/models/profile_summary.rb
Overview
The summary of information about the user profiles. It includes details such as profile name, failed login attempts, sessions per user, inactive account time, password lock time, user created, target id, and the compartment id.
Instance Attribute Summary collapse
-
#compartment_id ⇒ String
[Required] The OCID of the compartment that contains the user assessment.
-
#defined_tags ⇒ Hash<String, Hash<String, Object>>
Defined tags for this resource.
-
#failed_login_attempts ⇒ String
Maximum times the user is allowed to fail login before the user account is locked.
-
#freeform_tags ⇒ Hash<String, String>
Free-form tags for this resource.
-
#inactive_account_time ⇒ String
The permitted periods of continuous inactive time during a session, expressed in minutes.
-
#is_user_created ⇒ BOOLEAN
Represents if the profile is created by user.
-
#password_lock_time ⇒ String
Number of days the user account remains locked after failed login.
-
#password_verification_function ⇒ String
PL/SQL that can be used for password verification.
-
#profile_name ⇒ String
The name of the profile.
-
#sessions_per_user ⇒ String
The maximum number of sessions a user is allowed to create.
-
#target_id ⇒ String
The OCID of the target database.
-
#user_assessment_id ⇒ String
[Required] The OCID of the latest user assessment corresponding to the target under consideration.
-
#user_count ⇒ Integer
The number of users having a given profile.
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 = {}) ⇒ ProfileSummary
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 = {}) ⇒ ProfileSummary
Initializes the object
136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 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 215 216 217 218 219 |
# File 'lib/oci/data_safe/models/profile_summary.rb', line 136 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.user_assessment_id = attributes[:'userAssessmentId'] if attributes[:'userAssessmentId'] raise 'You cannot provide both :userAssessmentId and :user_assessment_id' if attributes.key?(:'userAssessmentId') && attributes.key?(:'user_assessment_id') self.user_assessment_id = attributes[:'user_assessment_id'] if attributes[:'user_assessment_id'] self.compartment_id = attributes[:'compartmentId'] if attributes[:'compartmentId'] raise 'You cannot provide both :compartmentId and :compartment_id' if attributes.key?(:'compartmentId') && attributes.key?(:'compartment_id') self.compartment_id = attributes[:'compartment_id'] if attributes[:'compartment_id'] self.target_id = attributes[:'targetId'] if attributes[:'targetId'] raise 'You cannot provide both :targetId and :target_id' if attributes.key?(:'targetId') && attributes.key?(:'target_id') self.target_id = attributes[:'target_id'] if attributes[:'target_id'] self.profile_name = attributes[:'profileName'] if attributes[:'profileName'] raise 'You cannot provide both :profileName and :profile_name' if attributes.key?(:'profileName') && attributes.key?(:'profile_name') self.profile_name = attributes[:'profile_name'] if attributes[:'profile_name'] self.user_count = attributes[:'userCount'] if attributes[:'userCount'] raise 'You cannot provide both :userCount and :user_count' if attributes.key?(:'userCount') && attributes.key?(:'user_count') self.user_count = attributes[:'user_count'] if attributes[:'user_count'] self.failed_login_attempts = attributes[:'failedLoginAttempts'] if attributes[:'failedLoginAttempts'] raise 'You cannot provide both :failedLoginAttempts and :failed_login_attempts' if attributes.key?(:'failedLoginAttempts') && attributes.key?(:'failed_login_attempts') self.failed_login_attempts = attributes[:'failed_login_attempts'] if attributes[:'failed_login_attempts'] self.password_verification_function = attributes[:'passwordVerificationFunction'] if attributes[:'passwordVerificationFunction'] raise 'You cannot provide both :passwordVerificationFunction and :password_verification_function' if attributes.key?(:'passwordVerificationFunction') && attributes.key?(:'password_verification_function') self.password_verification_function = attributes[:'password_verification_function'] if attributes[:'password_verification_function'] self.sessions_per_user = attributes[:'sessionsPerUser'] if attributes[:'sessionsPerUser'] raise 'You cannot provide both :sessionsPerUser and :sessions_per_user' if attributes.key?(:'sessionsPerUser') && attributes.key?(:'sessions_per_user') self.sessions_per_user = attributes[:'sessions_per_user'] if attributes[:'sessions_per_user'] self.inactive_account_time = attributes[:'inactiveAccountTime'] if attributes[:'inactiveAccountTime'] raise 'You cannot provide both :inactiveAccountTime and :inactive_account_time' if attributes.key?(:'inactiveAccountTime') && attributes.key?(:'inactive_account_time') self.inactive_account_time = attributes[:'inactive_account_time'] if attributes[:'inactive_account_time'] self.password_lock_time = attributes[:'passwordLockTime'] if attributes[:'passwordLockTime'] raise 'You cannot provide both :passwordLockTime and :password_lock_time' if attributes.key?(:'passwordLockTime') && attributes.key?(:'password_lock_time') self.password_lock_time = attributes[:'password_lock_time'] if attributes[:'password_lock_time'] self.is_user_created = attributes[:'isUserCreated'] unless attributes[:'isUserCreated'].nil? raise 'You cannot provide both :isUserCreated and :is_user_created' if attributes.key?(:'isUserCreated') && attributes.key?(:'is_user_created') self.is_user_created = attributes[:'is_user_created'] unless attributes[:'is_user_created'].nil? self. = attributes[:'freeformTags'] if attributes[:'freeformTags'] raise 'You cannot provide both :freeformTags and :freeform_tags' if attributes.key?(:'freeformTags') && attributes.key?(:'freeform_tags') self. = attributes[:'freeform_tags'] if attributes[:'freeform_tags'] self. = attributes[:'definedTags'] if attributes[:'definedTags'] raise 'You cannot provide both :definedTags and :defined_tags' if attributes.key?(:'definedTags') && attributes.key?(:'defined_tags') self. = attributes[:'defined_tags'] if attributes[:'defined_tags'] end |
Instance Attribute Details
#compartment_id ⇒ String
[Required] The OCID of the compartment that contains the user assessment.
21 22 23 |
# File 'lib/oci/data_safe/models/profile_summary.rb', line 21 def compartment_id @compartment_id end |
#defined_tags ⇒ Hash<String, Hash<String, Object>>
Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags
Example: {\"Operations\": {\"CostCenter\": \"42\"}}
73 74 75 |
# File 'lib/oci/data_safe/models/profile_summary.rb', line 73 def @defined_tags end |
#failed_login_attempts ⇒ String
Maximum times the user is allowed to fail login before the user account is locked.
37 38 39 |
# File 'lib/oci/data_safe/models/profile_summary.rb', line 37 def failed_login_attempts @failed_login_attempts end |
#freeform_tags ⇒ Hash<String, String>
Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags
Example: {\"Department\": \"Finance\"}
66 67 68 |
# File 'lib/oci/data_safe/models/profile_summary.rb', line 66 def @freeform_tags end |
#inactive_account_time ⇒ String
The permitted periods of continuous inactive time during a session, expressed in minutes. Long-running queries and other operations are not subjected to this limit.
51 52 53 |
# File 'lib/oci/data_safe/models/profile_summary.rb', line 51 def inactive_account_time @inactive_account_time end |
#is_user_created ⇒ BOOLEAN
Represents if the profile is created by user.
59 60 61 |
# File 'lib/oci/data_safe/models/profile_summary.rb', line 59 def is_user_created @is_user_created end |
#password_lock_time ⇒ String
Number of days the user account remains locked after failed login
55 56 57 |
# File 'lib/oci/data_safe/models/profile_summary.rb', line 55 def password_lock_time @password_lock_time end |
#password_verification_function ⇒ String
PL/SQL that can be used for password verification.
41 42 43 |
# File 'lib/oci/data_safe/models/profile_summary.rb', line 41 def password_verification_function @password_verification_function end |
#profile_name ⇒ String
The name of the profile.
29 30 31 |
# File 'lib/oci/data_safe/models/profile_summary.rb', line 29 def profile_name @profile_name end |
#sessions_per_user ⇒ String
The maximum number of sessions a user is allowed to create.
45 46 47 |
# File 'lib/oci/data_safe/models/profile_summary.rb', line 45 def sessions_per_user @sessions_per_user end |
#target_id ⇒ String
The OCID of the target database.
25 26 27 |
# File 'lib/oci/data_safe/models/profile_summary.rb', line 25 def target_id @target_id end |
#user_assessment_id ⇒ String
[Required] The OCID of the latest user assessment corresponding to the target under consideration. A compartment type assessment can also be passed to profiles from all the targets from the corresponding compartment.
17 18 19 |
# File 'lib/oci/data_safe/models/profile_summary.rb', line 17 def user_assessment_id @user_assessment_id end |
#user_count ⇒ Integer
The number of users having a given profile.
33 34 35 |
# File 'lib/oci/data_safe/models/profile_summary.rb', line 33 def user_count @user_count end |
Class Method Details
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 |
# File 'lib/oci/data_safe/models/profile_summary.rb', line 76 def self.attribute_map { # rubocop:disable Style/SymbolLiteral 'user_assessment_id': :'userAssessmentId', 'compartment_id': :'compartmentId', 'target_id': :'targetId', 'profile_name': :'profileName', 'user_count': :'userCount', 'failed_login_attempts': :'failedLoginAttempts', 'password_verification_function': :'passwordVerificationFunction', 'sessions_per_user': :'sessionsPerUser', 'inactive_account_time': :'inactiveAccountTime', 'password_lock_time': :'passwordLockTime', 'is_user_created': :'isUserCreated', 'freeform_tags': :'freeformTags', 'defined_tags': :'definedTags' # rubocop:enable Style/SymbolLiteral } end |
.swagger_types ⇒ Object
Attribute type mapping.
97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 |
# File 'lib/oci/data_safe/models/profile_summary.rb', line 97 def self.swagger_types { # rubocop:disable Style/SymbolLiteral 'user_assessment_id': :'String', 'compartment_id': :'String', 'target_id': :'String', 'profile_name': :'String', 'user_count': :'Integer', 'failed_login_attempts': :'String', 'password_verification_function': :'String', 'sessions_per_user': :'String', 'inactive_account_time': :'String', 'password_lock_time': :'String', 'is_user_created': :'BOOLEAN', 'freeform_tags': :'Hash<String, String>', 'defined_tags': :'Hash<String, Hash<String, Object>>' # rubocop:enable Style/SymbolLiteral } end |
Instance Method Details
#==(other) ⇒ Object
Checks equality by comparing each attribute.
228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 |
# File 'lib/oci/data_safe/models/profile_summary.rb', line 228 def ==(other) return true if equal?(other) self.class == other.class && user_assessment_id == other.user_assessment_id && compartment_id == other.compartment_id && target_id == other.target_id && profile_name == other.profile_name && user_count == other.user_count && failed_login_attempts == other.failed_login_attempts && password_verification_function == other.password_verification_function && sessions_per_user == other.sessions_per_user && inactive_account_time == other.inactive_account_time && password_lock_time == other.password_lock_time && is_user_created == other.is_user_created && == other. && == other. end |
#build_from_hash(attributes) ⇒ Object
Builds the object from hash
270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 |
# File 'lib/oci/data_safe/models/profile_summary.rb', line 270 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
250 251 252 |
# File 'lib/oci/data_safe/models/profile_summary.rb', line 250 def eql?(other) self == other end |
#hash ⇒ Fixnum
Calculates hash code according to all attributes.
259 260 261 |
# File 'lib/oci/data_safe/models/profile_summary.rb', line 259 def hash [user_assessment_id, compartment_id, target_id, profile_name, user_count, failed_login_attempts, password_verification_function, sessions_per_user, inactive_account_time, password_lock_time, is_user_created, , ].hash end |
#to_hash ⇒ Hash
Returns the object in the form of hash
303 304 305 306 307 308 309 310 311 312 |
# File 'lib/oci/data_safe/models/profile_summary.rb', line 303 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
297 298 299 |
# File 'lib/oci/data_safe/models/profile_summary.rb', line 297 def to_s to_hash.to_s end |