Remove register_implementation, warn about future deprecation
[gitmo/MooseX-AttributeHelpers.git] / lib / MooseX / AttributeHelpers / Trait / Collection / Hash.pm
CommitLineData
5646987e 1
2package MooseX::AttributeHelpers::Trait::Collection::Hash;
3use Moose::Role;
4
4a0da5ad 5our $VERSION = '0.19';
cf0d1310 6$VERSION = eval $VERSION;
5646987e 7our $AUTHORITY = 'cpan:STEVAN';
8
9use MooseX::AttributeHelpers::MethodProvider::Hash;
10
11with 'MooseX::AttributeHelpers::Trait::Collection';
12
13has 'method_provider' => (
14 is => 'ro',
15 isa => 'ClassName',
16 predicate => 'has_method_provider',
17 default => 'MooseX::AttributeHelpers::MethodProvider::Hash'
18);
19
20sub helper_type { 'HashRef' }
21
22no Moose::Role;
23
5646987e 241;
25
26__END__
27
28=pod
29
30=head1 NAME
31
32MooseX::AttributeHelpers::Collection::Hash
33
34=head1 SYNOPSIS
35
36 package Stuff;
37 use Moose;
38 use MooseX::AttributeHelpers;
cf0d1310 39
5646987e 40 has 'options' => (
41 metaclass => 'Collection::Hash',
42 is => 'ro',
43 isa => 'HashRef[Str]',
44 default => sub { {} },
45 provides => {
46 'set' => 'set_option',
cf0d1310 47 'get' => 'get_option',
5646987e 48 'empty' => 'has_options',
49 'count' => 'num_options',
50 'delete' => 'delete_option',
51 }
52 );
cf0d1310 53
5646987e 54=head1 DESCRIPTION
55
cf0d1310 56This module provides a Hash attribute which provides a number of
5646987e 57hash-like operations. See L<MooseX::AttributeHelpers::MethodProvider::Hash>
58for more details.
59
60=head1 METHODS
61
62=over 4
63
64=item B<meta>
65
66=item B<method_provider>
67
68=item B<has_method_provider>
69
70=item B<helper_type>
71
72=back
73
74=head1 BUGS
75
cf0d1310 76All complex software has bugs lurking in it, and this module is no
5646987e 77exception. If you find a bug please either email me, or add the bug
78to cpan-RT.
79
80=head1 AUTHOR
81
82Stevan Little E<lt>stevan@iinteractive.comE<gt>
83
84=head1 COPYRIGHT AND LICENSE
85
9c5d164e 86Copyright 2007-2009 by Infinity Interactive, Inc.
5646987e 87
88L<http://www.iinteractive.com>
89
90This library is free software; you can redistribute it and/or modify
91it under the same terms as Perl itself.
92
93=cut