2 package Moose::Meta::Attribute::Native::MethodProvider::Bool;
6 $VERSION = eval $VERSION;
7 our $AUTHORITY = 'cpan:STEVAN';
10 my ( $attr, $reader, $writer ) = @_;
11 return sub { $writer->( $_[0], 1 ) };
15 my ( $attr, $reader, $writer ) = @_;
16 return sub { $writer->( $_[0], 0 ) };
20 my ( $attr, $reader, $writer ) = @_;
21 return sub { $writer->( $_[0], !$reader->( $_[0] ) ) };
25 my ( $attr, $reader, $writer ) = @_;
26 return sub { !$reader->( $_[0] ) };
37 Moose::Meta::Attribute::Native::MethodProvider::Bool
41 This is a role which provides the method generators for
42 L<Moose::Meta::Attribute::Trait::Native::Bool>. Please check there for
43 documentation on what methods are provided.
55 All complex software has bugs lurking in it, and this module is no
56 exception. If you find a bug please either email me, or add the bug
61 Jason May E<lt>jason.a.may@gmail.comE<gt>
63 =head1 COPYRIGHT AND LICENSE
65 Copyright 2007-2009 by Infinity Interactive, Inc.
67 L<http://www.iinteractive.com>
69 This library is free software; you can redistribute it and/or modify
70 it under the same terms as Perl itself.