Class: OCI::DataSafe::Models::AuditPolicyDimensions
- Inherits:
-
Object
- Object
- OCI::DataSafe::Models::AuditPolicyDimensions
- Defined in:
- lib/oci/data_safe/models/audit_policy_dimensions.rb
Overview
Details of aggregation dimensions used for summarizing audit policies.
Constant Summary collapse
- AUDIT_POLICY_CATEGORY_ENUM =
[ AUDIT_POLICY_CATEGORY_BASIC_ACTIVITY = 'BASIC_ACTIVITY'.freeze, AUDIT_POLICY_CATEGORY_ADMIN_USER_ACTIVITY = 'ADMIN_USER_ACTIVITY'.freeze, AUDIT_POLICY_CATEGORY_USER_ACTIVITY = 'USER_ACTIVITY'.freeze, AUDIT_POLICY_CATEGORY_ORACLE_PREDEFINED = 'ORACLE_PREDEFINED'.freeze, AUDIT_POLICY_CATEGORY_COMPLIANCE_STANDARD = 'COMPLIANCE_STANDARD'.freeze, AUDIT_POLICY_CATEGORY_CUSTOM = 'CUSTOM'.freeze ].freeze
Instance Attribute Summary collapse
-
#audit_policy_category ⇒ String
The category to which the audit policy belongs.
-
#audit_policy_name ⇒ String
Indicates the audit policy name.
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 = {}) ⇒ AuditPolicyDimensions
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 = {}) ⇒ AuditPolicyDimensions
Initializes the object
56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 |
# File 'lib/oci/data_safe/models/audit_policy_dimensions.rb', line 56 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.audit_policy_category = attributes[:'auditPolicyCategory'] if attributes[:'auditPolicyCategory'] raise 'You cannot provide both :auditPolicyCategory and :audit_policy_category' if attributes.key?(:'auditPolicyCategory') && attributes.key?(:'audit_policy_category') self.audit_policy_category = attributes[:'audit_policy_category'] if attributes[:'audit_policy_category'] self.audit_policy_name = attributes[:'auditPolicyName'] if attributes[:'auditPolicyName'] raise 'You cannot provide both :auditPolicyName and :audit_policy_name' if attributes.key?(:'auditPolicyName') && attributes.key?(:'audit_policy_name') self.audit_policy_name = attributes[:'audit_policy_name'] if attributes[:'audit_policy_name'] end |
Instance Attribute Details
#audit_policy_category ⇒ String
The category to which the audit policy belongs.
21 22 23 |
# File 'lib/oci/data_safe/models/audit_policy_dimensions.rb', line 21 def audit_policy_category @audit_policy_category end |
#audit_policy_name ⇒ String
Indicates the audit policy name. Refer to the [documentation](docs.oracle.com/en/cloud/paas/data-safe/udscs/audit-policies.html#GUID-361A9A9A-7C21-4F5A-8945-9B3A0C472827) for seeded audit policy names. For custom policies, refer to the user-defined policy name created in the target database.
26 27 28 |
# File 'lib/oci/data_safe/models/audit_policy_dimensions.rb', line 26 def audit_policy_name @audit_policy_name end |
Class Method Details
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
29 30 31 32 33 34 35 36 |
# File 'lib/oci/data_safe/models/audit_policy_dimensions.rb', line 29 def self.attribute_map { # rubocop:disable Style/SymbolLiteral 'audit_policy_category': :'auditPolicyCategory', 'audit_policy_name': :'auditPolicyName' # rubocop:enable Style/SymbolLiteral } end |
.swagger_types ⇒ Object
Attribute type mapping.
39 40 41 42 43 44 45 46 |
# File 'lib/oci/data_safe/models/audit_policy_dimensions.rb', line 39 def self.swagger_types { # rubocop:disable Style/SymbolLiteral 'audit_policy_category': :'String', 'audit_policy_name': :'String' # rubocop:enable Style/SymbolLiteral } end |
Instance Method Details
#==(other) ⇒ Object
Checks equality by comparing each attribute.
90 91 92 93 94 95 96 |
# File 'lib/oci/data_safe/models/audit_policy_dimensions.rb', line 90 def ==(other) return true if equal?(other) self.class == other.class && audit_policy_category == other.audit_policy_category && audit_policy_name == other.audit_policy_name end |
#build_from_hash(attributes) ⇒ Object
Builds the object from hash
121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 |
# File 'lib/oci/data_safe/models/audit_policy_dimensions.rb', line 121 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
101 102 103 |
# File 'lib/oci/data_safe/models/audit_policy_dimensions.rb', line 101 def eql?(other) self == other end |
#hash ⇒ Fixnum
Calculates hash code according to all attributes.
110 111 112 |
# File 'lib/oci/data_safe/models/audit_policy_dimensions.rb', line 110 def hash [audit_policy_category, audit_policy_name].hash end |
#to_hash ⇒ Hash
Returns the object in the form of hash
154 155 156 157 158 159 160 161 162 163 |
# File 'lib/oci/data_safe/models/audit_policy_dimensions.rb', line 154 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
148 149 150 |
# File 'lib/oci/data_safe/models/audit_policy_dimensions.rb', line 148 def to_s to_hash.to_s end |