USURPING A CLASS
The class is not loaded, you want to keep it that way, and put something in it's place.
- Create the package, %INC is updated for you to prevent the real one from loading.
-
my $control = qimplement Some::Package => ( ... );
arguments
- auto-create new()
-
-with_new => 1, - subclassing
-
-subclass => $class || [ @CLASSES ], - quickly generate attributes (read/write)
-
-attributes => [qw/ foo bar baz /] - simple return value methods
-
method => 'value' - custom methods
-
do_it => sub { ... }
The control object returned is identical to that from qtakeover().