Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
..
Failed to load latest commit information.
test
README.md
index.js
package.json

README.md

hook

for managing event hooks ( IF this THEN that )

API

properties

methods

properties

for managing event hooks ( IF this THEN that )

  • id

    • type : any
  • if

    • type : string

    • description : the if action

    • required : true

  • then

    • type : string

    • description : the then action

    • required : true

  • with

    • type : object

    • description : additional data supplied to then

methods

hook.create(options, callback)

create a new hook

  • options

    • type : object

    • properties

      • id

        • type : any
      • if

        • type : string

        • description : the if action

        • required : true

      • then

        • type : string

        • description : the then action

        • required : true

      • with

        • type : object

        • description : additional data supplied to then

  • callback

    • type : function

hook.get(id, callback)

get hook by id

  • id

    • type : any

    • description : the id of the object

    • required : true

  • callback

    • type : function

hook.find(options, callback)

search for instances of hook

  • options

    • type : object

    • properties

      • id

        • type : any

        • default :

        • required : false

      • if

        • type : any

        • description : the if action

        • required : false

        • default :

      • then

        • type : any

        • description : the then action

        • required : false

        • default :

      • with

        • type : any

        • description : additional data supplied to then

        • default :

        • required : false

  • callback

    • type : function

hook.all(callback)

gets all instances of hook

  • callback

    • type : function

hook.update(options, callback)

updates a hook by id

  • options

    • type : object

    • properties

      • id

        • type : any
      • if

        • type : string

        • description : the if action

        • required : true

      • then

        • type : string

        • description : the then action

        • required : true

      • with

        • type : object

        • description : additional data supplied to then

  • callback

    • type : function

hook.updateOrCreate(options, callback)

updates a hook by id, and creates if necessary

  • options

    • type : object

    • properties

      • id

        • type : any
      • if

        • type : string

        • description : the if action

        • required : true

      • then

        • type : string

        • description : the then action

        • required : true

      • with

        • type : object

        • description : additional data supplied to then

  • callback

    • type : function

hook.destroy(id, callback)

destroys a hook by id

  • id

    • type : string

    • description : the id of the object

    • required : true

  • callback

    • type : function

hook.start()

loads all hooks into memory

hook.bind()

README auto-generated with docs