make github the primary repository
[gitmo/Moose.git] / lib / Moose / Meta / Mixin / AttributeCore.pm
1 package Moose::Meta::Mixin::AttributeCore;
2
3 use strict;
4 use warnings;
5
6 use base 'Class::MOP::Mixin::AttributeCore';
7
8 __PACKAGE__->meta->add_attribute(
9     'isa' => (
10         reader => '_isa_metadata',
11         Class::MOP::_definition_context(),
12     )
13 );
14
15 __PACKAGE__->meta->add_attribute(
16     'does' => (
17         reader => '_does_metadata',
18         Class::MOP::_definition_context(),
19     )
20 );
21
22 __PACKAGE__->meta->add_attribute(
23     'is' => (
24         reader => '_is_metadata',
25         Class::MOP::_definition_context(),
26     )
27 );
28
29 __PACKAGE__->meta->add_attribute(
30     'required' => (
31         reader => 'is_required',
32         Class::MOP::_definition_context(),
33     )
34 );
35
36 __PACKAGE__->meta->add_attribute(
37     'lazy' => (
38         reader => 'is_lazy', Class::MOP::_definition_context(),
39     )
40 );
41
42 __PACKAGE__->meta->add_attribute(
43     'lazy_build' => (
44         reader => 'is_lazy_build',
45         Class::MOP::_definition_context(),
46     )
47 );
48
49 __PACKAGE__->meta->add_attribute(
50     'coerce' => (
51         reader => 'should_coerce',
52         Class::MOP::_definition_context(),
53     )
54 );
55
56 __PACKAGE__->meta->add_attribute(
57     'weak_ref' => (
58         reader => 'is_weak_ref',
59         Class::MOP::_definition_context(),
60     )
61 );
62
63 __PACKAGE__->meta->add_attribute(
64     'auto_deref' => (
65         reader => 'should_auto_deref',
66         Class::MOP::_definition_context(),
67     )
68 );
69
70 __PACKAGE__->meta->add_attribute(
71     'type_constraint' => (
72         reader    => 'type_constraint',
73         predicate => 'has_type_constraint',
74         Class::MOP::_definition_context(),
75     )
76 );
77
78 __PACKAGE__->meta->add_attribute(
79     'trigger' => (
80         reader    => 'trigger',
81         predicate => 'has_trigger',
82         Class::MOP::_definition_context(),
83     )
84 );
85
86 __PACKAGE__->meta->add_attribute(
87     'handles' => (
88         reader    => 'handles',
89         writer    => '_set_handles',
90         predicate => 'has_handles',
91         Class::MOP::_definition_context(),
92     )
93 );
94
95 __PACKAGE__->meta->add_attribute(
96     'documentation' => (
97         reader    => 'documentation',
98         predicate => 'has_documentation',
99         Class::MOP::_definition_context(),
100     )
101 );
102
103 1;
104
105 # ABSTRACT: Core attributes shared by attribute metaclasses
106
107 __END__
108
109 =pod
110
111 =head1 DESCRIPTION
112
113 This class implements the core attributes (aka properties) shared by all Moose
114 attributes. See the L<Moose::Meta::Attribute> documentation for API details.
115
116 =head1 BUGS
117
118 See L<Moose/BUGS> for details on reporting bugs.
119
120 =cut