Class: Graphiti::OpenAPI::Endpoints
- Inherits:
-
Hash
- Object
- Hash
- Graphiti::OpenAPI::Endpoints
- Defined in:
- app/models/graphiti/open_api/endpoint.rb
Class Method Summary collapse
Class Method Details
.load(schema, data: ) ⇒ Object
66 67 68 69 70 |
# File 'app/models/graphiti/open_api/endpoint.rb', line 66 def self.load(schema, data: schema.__attributes__[:endpoints]) data.each_with_object({}) do |(path, data), result| result[path] = Endpoint.new(data.to_hash.merge(schema: schema, path: path)) end end |