Hooks ordering:
find, findAll afterGet get, getAll beforeGet, afterGet insert,insertAll beforeValidate, afterValidate, beforeInsert, afterInsert, afterGet
Hooks are called on each record, so getAll, findAll, and insertAll operations will call each hook for each record.
Subscribe a callable function to a namespace, for exactly one execution.
Used to manage the subscription status via open
and close
methods.
Remove a Listener instance from the EventNamespace instance. Called with unsubscribe
method.
A true value indicates a successful pop.
Add a Listener instance to the EventNamespace instance. Called with subscribe
method.
Hooks ordering:
Operation(s) Order
find, findAll afterGet get, getAll beforeGet, afterGet insert,insertAll beforeValidate, afterValidate, beforeInsert, afterInsert, afterGet
replace, update beforeValidate, afterValidate, beforeUpdate, afterUpdate, afterGet
Hooks are called on each record, so getAll, findAll, and insertAll operations will call each hook for each record.