Buy GNU books!
|[ < ]||[ > ]||[ << ]||[ Up ]||[ >> ]||[Top]||[Contents]||[Index]||[ ? ]|
A hook is a list of procedures to be called at well defined points in time. Typically, an application provides a hook h and promises its users that it will call all of the procedures in h at a defined point in the application's processing. By adding its own procedure to h, an application user can tap into or even influence the progress of the application.
Guile itself provides several such hooks for debugging and customization purposes: these are listed in a subsection below.
When an application first creates a hook, it needs to know how many arguments will be passed to the hook's procedures when the hook is run. The chosen number of arguments (which may be none) is declared when the hook is created, and all the procedures that are added to that hook must be capable of accepting that number of arguments.
A hook is created using
make-hook. A procedure can be added to
or removed from a hook using
and all of a hook's procedures can be removed together using
reset-hook!. When an application wants to run a hook, it does so
24.6.1 Hook Usage by Example Hook usage by example. 24.6.2 Hook Reference Reference of all hook procedures. 24.6.4 Hooks For C Code. Hooks for use from C code. 24.6.5 Hooks Provided by Guile Hooks provided by Guile.
|webmaster||delorie software privacy|
|Copyright © 2003 by The Free Software Foundation||Updated Jun 2003|