new Hook()
A collection of functions, provide serial processing and interaction between them
Works like a collection of callbacks. It can be a collection validators too
A function inside a hook which return false will prevent its next ones to be executed
Extends
Methods
exec(caller) → {Mixed}
Execute a Hook
Parameters:
Name | Type | Description |
---|---|---|
caller |
Object |
Returns:
Result returned from the last function
- Type
- Mixed
find(e) → {number}
Find index of element inside collection
- Inherited From:
flush()
Erase a collection
- Inherited From:
has(e) → {boolean}
Check if a collection contains an element
- Inherited From:
remove(e)
Remove an element
- Inherited From: