MHooks

MHooks ⇐ Trait

Allows to add hook feature to a class. A hook is the possibility to add a dynamic extension point in a method call.

Kind: global mixin
Extends: Trait
Example

$Class.declare("MyClass", {
 traits: [$MHooks, $MMyTrait],

 methods: {
  myFunc: function () {
   ...;
   this._callHooks("myFunc");
  }
 }
});
Trait.declare("MMyTrait", {
 methods: {
  myFunc$$MMyTrait: function () {
   ...
  }
 }
});