NAME
Genezzo::Havok::SysHook - load the SysHook table
SYNOPSIS
# don't say "use Genezzo::Havok::SysHook". Update the
# dictionary havok table:
insert into havok values (3, "Genezzo::Havok::SysHook", "SYSTEM", "2004-09-21T12:12", 0);
DESCRIPTION
Basic Havok module - load the SysHook table
create table sys_hook ( xid number, pkg char, hook char, replace char, xtype char, xname char, args char, owner char, creationdate char, version char );
- xid - a unique id number
- pkg - name of package for this hook
- hook - name of hook function
- replace - replacement strategy. If blank, null, or "replace", just replace existing hook. If "precede", new hook runs first, then activates previous, if it exists. If "follow", if old hook exists, it runs first, then activate new hook.
- xtype - the string "require" or "function"
- xname - if xtype = "require", then xname is a package name, like "Text::Soundex". if xtype = "function", xname is a function name. A function name may be qualified with a package.
- args - if xtype = "require", an (optional) blank-separated list of functions to import to the default Genezzo namespace. if xtype = "function", supply an actual function body in curly braces.
- owner - owner of the package or function
- creationdate - date row was created
Example:
insert into sys_hook (1, "Genezzo::Dict", "dicthook1", "require", "Genezzo::Havok::Examples", "Howdy", "SYSTEM", "2004-09-21T12:12");
The row causes SysHook to "require Genezzo::Havok::Examples", and calls the "Howdy" function from the hook function "dicthook1" in the package Genezzo::Dict.
? should it import unpackaged functions into the "pkg" package? Maybe if they don't have '::' in name...
ARGUMENTS
FUNCTIONS
- isRedGreen
EXPORT
LIMITATIONS
TODO
- Need to fix "import" mechanism so can load specific functions into Genezzo::GenDBI namespace, versus creating stub functions. Use "import" and "export_to_level".
- Could just load Acme::Everything and we'd be done...
AUTHOR
Jeffrey I. Cohen, jcohen@genezzo.com
SEE ALSO
Copyright (c) 2005 Jeffrey I Cohen. All rights reserved.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
Address bug reports and comments to: jcohen@genezzo.com
For more information, please visit the Genezzo homepage at http://www.genezzo.com