Class: DeleteNetworkPrivateElementTypeElementIDResponse400

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



3512
3513
3514
3515
3516
3517
3518
# File 'lib/schemas.rb', line 3512

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

.from_json!(json) ⇒ Object



3520
3521
3522
# File 'lib/schemas.rb', line 3520

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

Instance Method Details

#to_dynamicObject



3524
3525
3526
3527
3528
3529
# File 'lib/schemas.rb', line 3524

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

#to_json(options = nil) ⇒ Object



3531
3532
3533
# File 'lib/schemas.rb', line 3531

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