Class: PutNetworkPrivateNetworkEntityRequestRequestIDResponse401Error

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



34154
34155
34156
34157
34158
34159
34160
# File 'lib/schemas.rb', line 34154

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

.from_json!(json) ⇒ Object



34162
34163
34164
# File 'lib/schemas.rb', line 34162

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

Instance Method Details

#to_dynamicObject



34166
34167
34168
34169
34170
34171
# File 'lib/schemas.rb', line 34166

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

#to_json(options = nil) ⇒ Object



34173
34174
34175
# File 'lib/schemas.rb', line 34173

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