Hi, I'm developing a reusable subclass of CGI::Application. For this project I would like to have a new hook added to CGI::Application. The attached patch includes the changes I have made to my local copy for development. If anyone has any suggestions or anything please speak up. Otherwise, I'd like to see these changes included in the main distribution. -- Tony Fraser suppressed Sybaspace Internet Solutions System Administrator phone: (250) 246-5368 fax: (250) 246-5398
diff -ru CGI-Application-3.22/lib/CGI/Application.pm CGI-Application-3.23/lib/CGI/Application.pm
--- CGI-Application-3.22/lib/CGI/Application.pm 2004-08-30 18:01:23.000000000 -0700
+++ CGI-Application-3.23/lib/CGI/Application.pm 2004-08-30 18:36:04.000000000 -0700
@@ -4,7 +4,7 @@
use Carp;
use strict;
-$CGI::Application::VERSION = '3.22';
+$CGI::Application::VERSION = '3.23';
###################################
#### INSTANCE SCRIPT METHODS ####
@@ -169,6 +169,9 @@
# clean up operations
$self->teardown();
+ # Call cgiapp_finish() hook
+ $self->cgiapp_finish();
+
return $output;
}
@@ -216,6 +219,13 @@
}
+sub cgiapp_finish {
+ my $self = shift;
+
+ # Nothing to finish, yet!
+}
+
+
sub setup {
my $self = shift;
@@ -1136,6 +1146,13 @@
modes, and when a param() is a particular value.
+=item cgiapp_finish()
+
+If implemented, this hook will be called just before the run() method returns
+and after the simple teardown() method. Consider it to be the oppisite of the
+cgiapp_init() hook.
+
+
=item cgiapp_get_query()
This method is called when CGI::Application retrieves the CGI query object.
---------------------------------------------------------------------
Web Archive: http://www.mail-archive.com/suppressed/
http://marc.theaimsgroup.com/?l=cgiapp&r=1&w=2
To unsubscribe, e-mail: suppressed
For additional commands, e-mail: suppressed
Mail converted by mhonarc 2.6.15
This archive provided courtesy of JSW4.NET, Internet Hosting Services for Small Business.