The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

Venus::Role::Pluggable - Pluggable Role

ABSTRACT

Pluggable Role for Perl 5

SYNOPSIS

  package Example::Plugin::Password;

  use Venus::Class;

  use Digest::SHA ();

  sub execute {
    my ($self, $example) = @_;

    return Digest::SHA::sha1_hex($example->secret);
  }

  package Example;

  use Venus::Class;

  with 'Venus::Role::Proxyable';
  with 'Venus::Role::Pluggable';

  attr 'secret';

  package main;

  my $example = Example->new(secret => rand);

  # $example->password;

DESCRIPTION

This package provides a mechanism for dispatching to plugin classes.