Commit | Line | Data |
---|---|---|
e0a82090 | 1 | |
c0cbf4d9 | 2 | use lib reverse @INC; |
3 | ||
4 | package MOP::Installed::Point; | |
e0a82090 | 5 | |
6 | use strict; | |
7 | use warnings; | |
8 | use metaclass; | |
9 | ||
c0cbf4d9 | 10 | __PACKAGE__->meta->add_attribute('x' => (accessor => 'x', default => 10)); |
e0a82090 | 11 | __PACKAGE__->meta->add_attribute('y' => (accessor => 'y')); |
12 | ||
13 | sub new { | |
14 | my $class = shift; | |
15 | $class->meta->new_object(@_); | |
16 | } | |
17 | ||
18 | sub clear { | |
19 | my $self = shift; | |
20 | $self->x(0); | |
21 | $self->y(0); | |
22 | } | |
23 | ||
24 | 1; | |
25 | ||
26 | __END__ |