Managing modules
Users will be able to use Mesquite more effectively if they
become familar with the concepts of modules and how they interact.
An
understanding of the modular system will help the user more effectively
give commands to Mesquite via menus
and scripting, and interpret the
results obtained.
The page on how Mesquite works
introduces modules and how they cooperate. In brief, modules link
together to perform calculations and display the results to the
user. The linkage of modules is in the form of a tree, with the
root module being the "trunk" Mesquite module itself.
Which modules are currently active depends on the files the program
has read and the calculations the user has requested.
Installed versus loaded versus running modules
An installed module is one available to be used: it is
sitting as a file or a series of files on your disk or web server.
Mesquite can find these modules and, if approprate, can get them
started up. Among the installed modules might be some that you
never use, because you don't happen to need their calculations.
Not all installed modules are available to a user during a Mesquite
run. The reason is that, although a module might be physically
installed, it might not be loaded by Mesquite
at startup. An installed module might not be loaded if, for instance,
the user has chosen a configuration to control the loaded packages
(see Activate/Deactivate Packages in the File manue). The configuration
file might indicate that only some of the packages are to be loaded
and available.
When Mesquite starts up, or when the user requests new windows,
calculations, and so on, some of the loaded modules are started
up to do the work. These are the running modules.
This characterization is a bit misleading, however, since many
active copies of a single module on disk can be running at once.
That is, the installed module on disk can be thought of as a blueprint
for a machine, and each time Mesquite needs to start up a module,
the machine is built and started. If Mesquite needs another machine
of the same sort, it can build a new one from the blueprint. Many
machines (running modules) from a single blueprint (loaded module)
can be built and be running simultaneously.
(To the programmer, the loaded modules are the available classes
that are subclasses of the basic module class; an active module
is an object instantiated from one of these classes.)
Where modules are installed
To be installed and found by the Mesquite system, a module must
be within the mesquite directory of Mesquite_Folder.
Furthermore, the active configuration must specify that the module's
package be loaded. Be default, all installed packages are loaded.
Thus, if you open up the Mesquite_Folder, you might see the following
- com
- corejava
- docs
- documentation.html
- edu
- examples
- images
- Jama
- JSci
- lesser.txt
- pal
- mesquite. In this directory, you might see:
- ancstates
- assoc
- basic
- batchArch
- categ
- charMatrices
- charts
- coalesce
- configs
- cont
- distance
- genesis
- io
- jama
- jsci
- lib
- lists
- Mesquite.class
- minimal
- molec
- ornamental
- pairwise
- pal
- parsimony
- rhetenor
- search
- stochchar
- treefarm
- trees
- trunk
Each of the items in bold above is a directory (folder) that
contains modules. Within minimal, you might see:
- BasicFileCoordinator
- Defaults
- DrawHierarchy
- InterpretNEXUS
- ManageForeignBlocks
- (and so on)
Each of these directories is for one module. For a module to
be found and used by Mesquite, it must be present in a directory
whose name is the same as the class file for the module (e.g.,
the class file for the module "Basic File Coordinator",
BasicFileCoordinator.class, must be in a directory named BasicFileCoordinator).
Modules currently in use
While Mesquite is running you may want to learn what modules
are currently running. In the Help menu the Active
Module Tree menu item displays a window that displays
the modules currently running. You can also see the modules
responsible for any window by touching on the Modules tab in
the window's information bar.
If you touch on
the name of the module in theses module tree displays, a menu
will drop down that allows you to find out information about
the module.
Information pages and Manuals for modules
Mesquite gathers information about each module and summarizes
it in an information page for each module. These are linked
from the page available via the Modules Loaded menu item
in the Help menu while Mesquite is running. As well, some
individual modules have their own manuals in the form of
web pages. These are also linked from the Modules Loaded web page.