Class: GetMocksMockIDServerResponsesResponse401
- Inherits:
-
Dry::Struct
- Object
- Dry::Struct
- GetMocksMockIDServerResponsesResponse401
- Defined in:
- lib/schemas.rb
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.from_dynamic!(d) ⇒ Object
11515 11516 11517 11518 11519 11520 |
# File 'lib/schemas.rb', line 11515 def self.from_dynamic!(d) d = Types::Hash[d] new( error: d["error"] ? GetMocksMockIDServerResponsesResponse401Error.from_dynamic!(d["error"]) : nil, ) end |
.from_json!(json) ⇒ Object
11522 11523 11524 |
# File 'lib/schemas.rb', line 11522 def self.from_json!(json) from_dynamic!(JSON.parse(json)) end |
Instance Method Details
#to_dynamic ⇒ Object
11526 11527 11528 11529 11530 |
# File 'lib/schemas.rb', line 11526 def to_dynamic { "error" => error&.to_dynamic, } end |
#to_json(options = nil) ⇒ Object
11532 11533 11534 |
# File 'lib/schemas.rb', line 11532 def to_json( = nil) JSON.generate(to_dynamic, ) end |