Class: DeleteNetworkPrivateElementTypeElementIDResponse403Error

Inherits:
Dry::Struct
  • Object
show all
Defined in:
lib/schemas.rb

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.from_dynamic!(d) ⇒ Object



3601
3602
3603
3604
3605
3606
3607
# File 'lib/schemas.rb', line 3601

def self.from_dynamic!(d)
  d = Types::Hash[d]
  new(
    message:                                                               d["message"],
    delete_network_private_element_type_element_id_response403_error_name: d["name"],
  )
end

.from_json!(json) ⇒ Object



3609
3610
3611
# File 'lib/schemas.rb', line 3609

def self.from_json!(json)
  from_dynamic!(JSON.parse(json))
end

Instance Method Details

#to_dynamicObject



3613
3614
3615
3616
3617
3618
# File 'lib/schemas.rb', line 3613

def to_dynamic
  {
    "message" => message,
    "name"    => delete_network_private_element_type_element_id_response403_error_name,
  }
end

#to_json(options = nil) ⇒ Object



3620
3621
3622
# File 'lib/schemas.rb', line 3620

def to_json(options = nil)
  JSON.generate(to_dynamic, options)
end