Class: PutApisAPIIDSchemasSchemaIDFilesFilePathResponse403

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



28776
28777
28778
28779
28780
28781
28782
28783
# File 'lib/schemas.rb', line 28776

def self.from_dynamic!(d)
  d = Types::Hash[d]
  new(
    detail:                                                             d["detail"],
    title:                                                              d["title"],
    put_apis_api_id_schemas_schema_id_files_file_path_response403_type: d["type"],
  )
end

.from_json!(json) ⇒ Object



28785
28786
28787
# File 'lib/schemas.rb', line 28785

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

Instance Method Details

#to_dynamicObject



28789
28790
28791
28792
28793
28794
28795
# File 'lib/schemas.rb', line 28789

def to_dynamic
  {
    "detail" => detail,
    "title"  => title,
    "type"   => put_apis_api_id_schemas_schema_id_files_file_path_response403_type,
  }
end

#to_json(options = nil) ⇒ Object



28797
28798
28799
# File 'lib/schemas.rb', line 28797

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