Class: Controller

Controller

new Controller(options)

Parameters:
Name Type Description
options Object Object containing the properties listed below
Properties:
Name Type Description
model String Reference to a name of a model, if specified and valid, this.controller will contain the model instance.

Methods

list(req) → {Promise.<Object>}

Returns a list of all models, if a (valid) model is defined, if not, throws an Error. Returns the models on the collection property on the resolved object.
Parameters:
Name Type Description
req ControllerRequest
Returns:
Type
Promise.<Object>
Rik Hoffbauer 2015
Documentation generated by JSDoc 3.4.0 on 2015-12-03T17:30:45+01:00