On 30 Aug 2006 13:30:12 -0700, Randal L. Schwartz <merlyn@stonehenge.com> wrote:
> >>>>> "John" == John Siracusa <[EMAIL PROTECTED]> writes:
> John>   package My::Product::Manager;
> John>   ...
> John>   sub get_average_prices_by_type
> John>   {
> John>     my($class) = shift;
>
> John>     my $meta = My::Product->meta;
>
> Shouldn't that be $class->meta, in case you want to subclass
> and horse around, or even promote and reuse?

$class here is My::Product::Manager, not My::Product.  So it'd be
$class->object_class->meta (...provided you've correctly overridden
the object_class() method in your Manager subclass.  It's not strictly
necessary to do so, which is why I wrote it the way I did originally.)

-John

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Rose-db-object mailing list
Rose-db-object@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rose-db-object

Reply via email to