Class: Clerk::Models::Components::Machine

Inherits:
Object
  • Object
show all
Includes:
Crystalline::MetadataFields
Defined in:
lib/clerk/models/components/machine.rb

Instance Method Summary collapse

Methods included from Crystalline::MetadataFields

#field, #fields, included, #marshal_single, #to_dict, #to_json

Constructor Details

#initialize(object:, id:, name:, instance_id:, created_at:, updated_at:, scoped_machines:, default_token_ttl: 3600) ⇒ Machine

Returns a new instance of Machine.



33
34
35
36
37
38
39
40
41
42
# File 'lib/clerk/models/components/machine.rb', line 33

def initialize(object:, id:, name:, instance_id:, created_at:, updated_at:, scoped_machines:, default_token_ttl: 3600)
  @object = object
  @id = id
  @name = name
  @instance_id = instance_id
  @created_at = created_at
  @updated_at = updated_at
  @scoped_machines = scoped_machines
  @default_token_ttl = default_token_ttl
end

Instance Method Details

#==(other) ⇒ Object



45
46
47
48
49
50
51
52
53
54
55
56
# File 'lib/clerk/models/components/machine.rb', line 45

def ==(other)
  return false unless other.is_a? self.class
  return false unless @object == other.object
  return false unless @id == other.id
  return false unless @name == other.name
  return false unless @instance_id == other.instance_id
  return false unless @created_at == other.created_at
  return false unless @updated_at == other.updated_at
  return false unless @scoped_machines == other.scoped_machines
  return false unless @default_token_ttl == other.default_token_ttl
  true
end