perlquestion
water
Hi --
I have a set of classes like this:
<code>
package A;
# much base code which Does The Right Thing based on subclass type
# thru ref($self) inspection
1;
package B1;
use base(qw(A));
# no code here
1;
package B2;
use base(qw(A));
# no code here
1;
package B3;
use base(qw(A));
# no code here
1;
etc
</code>
That is, I set up a bunch of superthin subclasses of a base class -- they only differ between themselves in the class name.
<p>
Is there a way to dynamically generate the B1 ... Bn classes on the fly at execution, vs. creating them in B1.pm, B2.pm, etc. ?
<p>
[water]