Class: GetCollectionsCollectionIDResponsesResponseIDResponse401Error
- Inherits:
-
Dry::Struct
- Object
- Dry::Struct
- GetCollectionsCollectionIDResponsesResponseIDResponse401Error
- Defined in:
- lib/schemas.rb
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.from_dynamic!(d) ⇒ Object
8407 8408 8409 8410 8411 8412 8413 8414 |
# File 'lib/schemas.rb', line 8407 def self.from_dynamic!(d) d = Types::Hash[d] new( details: d["details"] ? GetCollectionsCollectionIDResponsesResponseIDResponse401ErrorDetails.from_dynamic!(d["details"]) : nil, message: d["message"], get_collections_collection_id_responses_response_id_response401_error_name: d["name"], ) end |
.from_json!(json) ⇒ Object
8416 8417 8418 |
# File 'lib/schemas.rb', line 8416 def self.from_json!(json) from_dynamic!(JSON.parse(json)) end |
Instance Method Details
#to_dynamic ⇒ Object
8420 8421 8422 8423 8424 8425 8426 |
# File 'lib/schemas.rb', line 8420 def to_dynamic { "details" => details&.to_dynamic, "message" => , "name" => get_collections_collection_id_responses_response_id_response401_error_name, } end |
#to_json(options = nil) ⇒ Object
8428 8429 8430 |
# File 'lib/schemas.rb', line 8428 def to_json( = nil) JSON.generate(to_dynamic, ) end |