API Docs for Version: 2.1.2
getOwner
child
Defined in src/containment.js:5
src/containment.js:5
Get the owner of an object
object from which to fetch the parent
parent (owner)
class UserController extends parch.Controller { doStuff(req, res, next) { const store = getOwner(this).lookup("service:store"); return store.findAll(); } }
setOwner
parent
Defined in src/containment.js:26
src/containment.js:26
Set the owner object of the child object
child object
parent (owner) object
setOwner({}, "service:store", "store"); {}.store