Class: DeleteMocksMockIDResponse429
- Inherits:
-
Dry::Struct
- Object
- Dry::Struct
- DeleteMocksMockIDResponse429
- Defined in:
- lib/schemas.rb
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.from_dynamic!(d) ⇒ Object
2419 2420 2421 2422 2423 2424 2425 |
# File 'lib/schemas.rb', line 2419 def self.from_dynamic!(d) d = Types::Hash[d] new( error: d["error"], message: d["message"], ) end |
.from_json!(json) ⇒ Object
2427 2428 2429 |
# File 'lib/schemas.rb', line 2427 def self.from_json!(json) from_dynamic!(JSON.parse(json)) end |
Instance Method Details
#to_dynamic ⇒ Object
2431 2432 2433 2434 2435 2436 |
# File 'lib/schemas.rb', line 2431 def to_dynamic { "error" => error, "message" => , } end |
#to_json(options = nil) ⇒ Object
2438 2439 2440 |
# File 'lib/schemas.rb', line 2438 def to_json( = nil) JSON.generate(to_dynamic, ) end |