NAME
Uttu::Framework - inheritable module providing basic framework support
SYNOPSIS
package Uttu::Framework::Sample;
use Uttu::Framework;
use vars qw{ @ISA };
@ISA = qw{ Uttu::Framework };
1;
DESCRIPTION
This provides basic configuration support for frameworks. All Perl modules whose names begin with the name of the framework (i.e., Uttu::Framework::Sample::*) will be loaded during server configuration time if the global_framework
configuration option is set to the name of the framework (e.g., Sample
for the above framework).
METHODS
- init
-
$framework -> init();
This defines any configuration variables available for the framework. The default method supplied by this module will search for any packages with the name of the framework (e.g., Uttu::Framework::Uttu->init() will search for Uttu::Framework::Uttu::*).
If this function returns a non-true value or throws an exception, the framework is considered invalid.
- init_config
-
$framework -> init_config($app_config);
This may be defined to set reasonable defaults for configuration variables. This is called after
init()
. An example of a configuration setting that might be set in this call is theglobal_content_handler
since a framework usually has a pretty good idea if it needs HTML::Mason, the Template Toolkit, or some other handler.If this function returns a non-true value or throws an exception, the framework is considered invalid.
AUTHOR
James G. Smith <jsmith@cpan.org>
COPYRIGHT
Copyright (C) 2002 Texas A&M University. All Rights Reserved.
This module is free software; you can redistribute it and/or modify it under the same terms as Perl itself.