in reply to Multiple Inheritance (DBIx::Class)

To slightly elaborate on my problem:

All my classes have a save() method which save the class-specific attributes to the database. Subclasses call SUPER::save() in this method and only handle their own, additional, attributes.

Now I need a way to

a. inherit the attributes of two different subclasses into a single class (composed of two arbitrary combinations of subclasses; e.g. a Vehicle that is a Vehicle::Car AND a Vehicle::Airplane)

b. make a save() call to this combined subclass that calls BOTH subclasses's save() methods. This will call SUPER::save() twice, but I can live with that.

Is there a way to do this dynamically, short of writing a package that inherits from both subclasses for every possible combination of two subclasses?

Replies are listed 'Best First'.
Re^2: Multiple Inheritance (DBIx::Class)
by rovf (Priest) on Jun 15, 2009 at 13:13 UTC