Hooks Methodology
Module Development
Hooks are stored in the hooks table in the database. As a module developer, it's your responsibility to "register" them - i.e. add them to the database table so that they get processed at the locations / times you want.
The benefit of storing them in the database prevents the need for the Core code to import all module code files for each request and process them each individually - which can slow down the script. Instead, this lets the code know precisely which module hooks need to be executed for which function.
For code hooks, the following information is needed:
Form Tools comes with functions to add, retrieve and delete your hooks. Generally, the best approach to registering hooks is to register them in your installation function. However, you can register them "on the fly" within your own module, based on user input if that is more appropriate to your needs.