Class: WorkOS::DsyncActivatedData
- Inherits:
-
Types::BaseModel
- Object
- Types::BaseModel
- WorkOS::DsyncActivatedData
- Defined in:
- lib/workos/directory_sync/dsync_activated_data.rb
Constant Summary collapse
- HASH_ATTRS =
{ object: :object, id: :id, organization_id: :organization_id, type: :type, state: :state, name: :name, created_at: :created_at, updated_at: :updated_at, external_key: :external_key, domains: :domains }.freeze
Instance Attribute Summary collapse
-
#created_at ⇒ Object
Returns the value of attribute created_at.
-
#domains ⇒ Object
Returns the value of attribute domains.
-
#external_key ⇒ Object
Returns the value of attribute external_key.
-
#id ⇒ Object
Returns the value of attribute id.
-
#name ⇒ Object
Returns the value of attribute name.
-
#object ⇒ Object
Returns the value of attribute object.
-
#organization_id ⇒ Object
Returns the value of attribute organization_id.
-
#state ⇒ Object
Returns the value of attribute state.
-
#type ⇒ Object
Returns the value of attribute type.
-
#updated_at ⇒ Object
Returns the value of attribute updated_at.
Attributes inherited from Types::BaseModel
Instance Method Summary collapse
-
#initialize(json) ⇒ DsyncActivatedData
constructor
A new instance of DsyncActivatedData.
Methods inherited from Types::BaseModel
Methods included from HashProvider
Constructor Details
#initialize(json) ⇒ DsyncActivatedData
Returns a new instance of DsyncActivatedData.
32 33 34 35 36 37 38 39 40 41 42 43 44 |
# File 'lib/workos/directory_sync/dsync_activated_data.rb', line 32 def initialize(json) hash = self.class.normalize(json) @object = hash[:object] @id = hash[:id] @organization_id = hash[:organization_id] @type = hash[:type] @state = hash[:state] @name = hash[:name] @created_at = hash[:created_at] @updated_at = hash[:updated_at] @external_key = hash[:external_key] @domains = (hash[:domains] || []).map { |item| item ? WorkOS::DsyncActivatedDataDomain.new(item) : nil } end |
Instance Attribute Details
#created_at ⇒ Object
Returns the value of attribute created_at.
20 21 22 |
# File 'lib/workos/directory_sync/dsync_activated_data.rb', line 20 def created_at @created_at end |
#domains ⇒ Object
Returns the value of attribute domains.
20 21 22 |
# File 'lib/workos/directory_sync/dsync_activated_data.rb', line 20 def domains @domains end |
#external_key ⇒ Object
Returns the value of attribute external_key.
20 21 22 |
# File 'lib/workos/directory_sync/dsync_activated_data.rb', line 20 def external_key @external_key end |
#id ⇒ Object
Returns the value of attribute id.
20 21 22 |
# File 'lib/workos/directory_sync/dsync_activated_data.rb', line 20 def id @id end |
#name ⇒ Object
Returns the value of attribute name.
20 21 22 |
# File 'lib/workos/directory_sync/dsync_activated_data.rb', line 20 def name @name end |
#object ⇒ Object
Returns the value of attribute object.
20 21 22 |
# File 'lib/workos/directory_sync/dsync_activated_data.rb', line 20 def object @object end |
#organization_id ⇒ Object
Returns the value of attribute organization_id.
20 21 22 |
# File 'lib/workos/directory_sync/dsync_activated_data.rb', line 20 def organization_id @organization_id end |
#state ⇒ Object
Returns the value of attribute state.
20 21 22 |
# File 'lib/workos/directory_sync/dsync_activated_data.rb', line 20 def state @state end |
#type ⇒ Object
Returns the value of attribute type.
20 21 22 |
# File 'lib/workos/directory_sync/dsync_activated_data.rb', line 20 def type @type end |
#updated_at ⇒ Object
Returns the value of attribute updated_at.
20 21 22 |
# File 'lib/workos/directory_sync/dsync_activated_data.rb', line 20 def updated_at @updated_at end |