perl-modperl mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mark Hedges <hed...@scriptdolphin.org>
Subject Re: a2c controller method names
Date Thu, 01 Jan 2009 21:22:03 GMT


On Thu, 1 Jan 2009, Mark Hedges wrote:
>
> Regarding your comment about inheritance vs. references -
> something I hadn't thought much about.  A) I need to prefix
> all my internal method names with 'a2c_' to stay out of
> the controller namespace.  B) You can't have any controller
> subroutines with the same names as anything in the
> Apache2::Request* family, which (slightly) limits your
> choice of allowable URL's.  But I think it's worth it so
> that '$self' is the Apache object.  What do people think?

Talking to myself again. I think I can make it work either
way.  Apache2::Controller won't use Apache2::Request as a
base, but it will still instantiate the Apache2::Request
object and put it in $self->{r}.  Then if you want to use
Apache2::Request as a base in your controller module to
access those methods via $self, you can.  Otherwise, don't.

Mark

Mime
View raw message