From: Tomas Doran Date: Sat, 18 Jul 2009 10:12:51 +0000 (+0000) Subject: Document the method name I actually added, idiot X-Git-Tag: 5.80008~42^2~1 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=catagits%2FCatalyst-Runtime.git;a=commitdiff_plain;h=4d38cb074da32815d87f1fb9fe7c03b761fdf15a;hp=fb0c5b21c3c972bc88b8c6c481f9937f31658a23 Document the method name I actually added, idiot --- diff --git a/lib/Catalyst/Action.pm b/lib/Catalyst/Action.pm index 8d187a0..fdb237c 100644 --- a/lib/Catalyst/Action.pm +++ b/lib/Catalyst/Action.pm @@ -103,8 +103,8 @@ and so on. This determines how the action is dispatched to. =head2 class -Returns the class name of the component where this action is defined. -Derived by calling the L +Returns the name of the component where this action is defined. +Derived by calling the L method on each component. =head2 code diff --git a/lib/Catalyst/Component.pm b/lib/Catalyst/Component.pm index d069278..c065664 100644 --- a/lib/Catalyst/Component.pm +++ b/lib/Catalyst/Component.pm @@ -172,13 +172,14 @@ something like this: return $class->new($app, $args); } -=head2 _component_class +=head2 _component_name -The class name of the component within an application. This is used to -pass the component's class name to actions generated (becoming +The name of the component within an application. This is used to +pass the component's name to actions generated (becoming C<< $action->class >>). This is needed so that the L method can return an instance of a different class (e.g. a L anonymous class), -and should be used to retrieve a component instead of C<< ref($self) >>. +(as finding the component name by C<< ref($self) >> will not work correctly in +such cases). =head2 $c->config