X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=lib%2FCatalyst%2FManual%2FWritingPlugins.pod;h=5af1713d93adf5f62bd374401860589addb115f4;hb=1b1636b58ce5f1feabd0d125c3928c57e5a5cf3c;hp=c44bbb7b01d5089c5626170a28ecc38ac0a7fe62;hpb=b3906aa256bbaf4f426b3733e1a9cfbf58fe6b31;p=catagits%2FCatalyst-Runtime.git diff --git a/lib/Catalyst/Manual/WritingPlugins.pod b/lib/Catalyst/Manual/WritingPlugins.pod index c44bbb7..5af1713 100644 --- a/lib/Catalyst/Manual/WritingPlugins.pod +++ b/lib/Catalyst/Manual/WritingPlugins.pod @@ -25,7 +25,7 @@ This technique is the usual way to plug a module into Catalyst. =head1 INTEGRATING YOUR PLUGIN -You can use L for your lugin by overloading certain methods which +You can use L for your plugin by overloading certain methods which are called by Catalyst during a request. =head2 The request life-cycle @@ -108,7 +108,7 @@ the rest of the arguments to the next handler in row by calling it via $c->NEXT::handler-name( @_ ); if you already Ced it out of C<@_>. Remember to C C. - + =head2 Storage and Configuration Some Plugins use their accessor names as a storage point, e.g. @@ -131,16 +131,16 @@ Here's a simple example Plugin that shows how to overload C to add a unique ID to every request: package Catalyst::Plugin::RequestUUID; - + use warnings; use strict; - + use Catalyst::Request; use Data::UUID; use NEXT; our $VERSION = 0.01; - + { # create a uuid accessor package Catalyst::Request; __PACKAGE__->mk_accessors('uuid'); @@ -148,7 +148,8 @@ to add a unique ID to every request: sub prepare { my $class = shift; - + + # Turns the engine-specific request into a Catalyst context . my $c = $class->NEXT::prepare( @_ ); $c->request->uuid( Data::UUID->new->create_str ); @@ -248,6 +249,6 @@ under the same terms as Perl itself. =head1 AUTHOR S> with a lot of help from the -poeple on #catalyst. +people on #catalyst. =cut