Class: WorkOS::AuditLogSchemaJsonTarget
- Inherits:
-
Types::BaseModel
- Object
- Types::BaseModel
- WorkOS::AuditLogSchemaJsonTarget
- Defined in:
- lib/workos/audit_logs/audit_log_schema_json_target.rb
Constant Summary collapse
- HASH_ATTRS =
{ type: :type, metadata: :metadata }.freeze
Instance Attribute Summary collapse
-
#metadata ⇒ Object
Returns the value of attribute metadata.
-
#type ⇒ Object
Returns the value of attribute type.
Attributes inherited from Types::BaseModel
Instance Method Summary collapse
-
#initialize(json) ⇒ AuditLogSchemaJsonTarget
constructor
A new instance of AuditLogSchemaJsonTarget.
Methods inherited from Types::BaseModel
Methods included from HashProvider
Constructor Details
#initialize(json) ⇒ AuditLogSchemaJsonTarget
Returns a new instance of AuditLogSchemaJsonTarget.
16 17 18 19 20 |
# File 'lib/workos/audit_logs/audit_log_schema_json_target.rb', line 16 def initialize(json) hash = self.class.normalize(json) @type = hash[:type] @metadata = hash[:metadata] || {} end |
Instance Attribute Details
#metadata ⇒ Object
Returns the value of attribute metadata.
12 13 14 |
# File 'lib/workos/audit_logs/audit_log_schema_json_target.rb', line 12 def @metadata end |
#type ⇒ Object
Returns the value of attribute type.
12 13 14 |
# File 'lib/workos/audit_logs/audit_log_schema_json_target.rb', line 12 def type @type end |