Class: PuzzlyApiPlugin::SchemasView
- Inherits:
-
Renderable
- Object
- Hash
- JSONable
- Renderable
- PuzzlyApiPlugin::SchemasView
- Defined in:
- lib/puzzly_api_plugin/view/schemas.rb
Constant Summary collapse
- API_ENDPOINT =
'schemas/home'
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(schemas) ⇒ SchemasView
constructor
A new instance of SchemasView.
Methods inherited from Renderable
#apis, #caches, #contexts, #modules, #path, #queries, #render, #schemas, #tables, #topics
Methods inherited from JSONable
Constructor Details
#initialize(schemas) ⇒ SchemasView
Returns a new instance of SchemasView.
18 19 20 21 |
# File 'lib/puzzly_api_plugin/view/schemas.rb', line 18 def initialize(schemas) super(API_ENDPOINT) self.schemas schemas end |
Class Method Details
.create ⇒ Object
8 9 10 11 12 13 14 15 16 |
# File 'lib/puzzly_api_plugin/view/schemas.rb', line 8 def self.create schemas = [] SchemasCollection.instance.each do |id, mod| schemas.push SchemaView.create(mod) end SchemasView.new(schemas) end |