Class: PostMocksMockIDServerResponsesResponse401
- Inherits:
-
Dry::Struct
- Object
- Dry::Struct
- PostMocksMockIDServerResponsesResponse401
- Defined in:
- lib/schemas.rb
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.from_dynamic!(d) ⇒ Object
24389 24390 24391 24392 24393 24394 |
# File 'lib/schemas.rb', line 24389 def self.from_dynamic!(d) d = Types::Hash[d] new( error: d["error"] ? PostMocksMockIDServerResponsesResponse401Error.from_dynamic!(d["error"]) : nil, ) end |
.from_json!(json) ⇒ Object
24396 24397 24398 |
# File 'lib/schemas.rb', line 24396 def self.from_json!(json) from_dynamic!(JSON.parse(json)) end |
Instance Method Details
#to_dynamic ⇒ Object
24400 24401 24402 24403 24404 |
# File 'lib/schemas.rb', line 24400 def to_dynamic { "error" => error&.to_dynamic, } end |
#to_json(options = nil) ⇒ Object
24406 24407 24408 |
# File 'lib/schemas.rb', line 24406 def to_json( = nil) JSON.generate(to_dynamic, ) end |