in reply to Extending objects
> And, please, I don't want to know how to do it with Moose.
Have been using Object::InsideOut recently. I find it can fit inside one's mind all at the same time. Unlike moose, where the bits keep falling out ... :-)
O::IO supports multiple inheritance, so one could write the following. (If all you required was already implemented in Foo and Bar, this really would be all the code.)
package MyProject::FooBar; { use Object::InsideOut qw(MyProject::Foo MyProject::Bar); } 1;
Example of use
my $foobar = MyProject::FooBar->new( name=>'Bob', age=>32 );
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Extending objects
by nudge (Acolyte) on Jul 08, 2010 at 02:38 UTC |