use Moose;
use MooseX::AttributeHelpers::MethodProvider::Bool;
-our $VERSION = '0.02';
+our $VERSION = '0.17';
+$VERSION = eval $VERSION;
our $AUTHORITY = 'cpan:STEVAN';
extends 'MooseX::AttributeHelpers::Base';
has '+method_provider' => (
default => 'MooseX::AttributeHelpers::MethodProvider::Bool'
);
-
+
+before 'process_options_for_provides' => sub {
+ my ($self, $options, $name) = @_;
+
+ # Set some default attribute options here unless already defined
+ if ((my $type = $self->helper_type) && !exists $options->{isa}){
+ $options->{isa} = $type;
+ }
+};
+
no Moose;
# register the alias ...
has 'is_lit' => (
metaclass => 'Bool',
is => 'rw',
- isa => 'Int',
+ isa => 'Bool',
default => sub { 0 },
provides => {
set => 'illuminate',
=item B<method_constructors>
+=item B<has_method_provider>
+
+=item B<method_provider>
+
=back
=head1 PROVIDED METHODS