Appends a search path to the list of paths where to look for plugins.
A so-called "search path" actually consists of both a module directory (where the shared libraries or language modules lie) and a data directory (where the plugin data is).
The plugin will be able to use a correct data dir depending on where it is installed, hence allowing to keep the plugin agnostic when it comes to installation location: the same plugin can be installed either in the system path or in the user's home directory, without taking other special care than using [[email protected]_data_dir] when looking for its data files.
If data_dir
is null, then it is set to the same value as module_dir
.
this |
A Engine. |
module_dir |
the plugin module directory. |
data_dir |
the plugin data directory. |