Skip to content

Instantly share code, notes, and snippets.

@perigrin
Created December 9, 2010 20:28
Show Gist options
  • Select an option

  • Save perigrin/735282 to your computer and use it in GitHub Desktop.

Select an option

Save perigrin/735282 to your computer and use it in GitHub Desktop.
package Wrapper;
use Moose;
use CPAN::Thing;
has cpan_thing => (
isa => 'CPAN::Thing',
handles => [qw(list of methods)],
default => sub { my $self = shift; CPAN::Thing->new( arg1 => $self->arg1, arg2 => $self->arg2 ) },
);
has arg1 ( ... );
has arg2 ( ... );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment