foo
[gitmo/MooseX-Storage.git] / lib / MooseX / Storage / Meta / Attribute / DoNotSerialize.pm
1
2 package MooseX::Storage::Meta::Attribute::DoNotSerialize;
3 use Moose;
4
5 extends 'Moose::Meta::Attribute';
6
7 # register this alias ...
8 package Moose::Meta::Attribute::Custom::DoNotSerialize;
9 sub register_implementation { 'MooseX::Storage::Meta::Attribute::DoNotSerialize' }
10
11 1;
12
13 __END__
14
15 =pod
16
17 =head1 NAME
18
19 MooseX::Storage::Meta::Attribute::DoNotSerialize
20
21 =head1 SYNOPSIS
22
23   package Point;
24   use Moose;
25   use MooseX::Storage;
26   
27   with Storage('format' => 'JSON', 'io' => 'File');
28   
29   has 'x' => (is => 'rw', isa => 'Int');
30   has 'y' => (is => 'rw', isa => 'Int');
31   
32   has 'foo' => (
33       metaclass => 'DoNotSerialize',
34       is        => 'rw',
35       isa       => 'CodeRef',
36   );
37   
38   1;
39
40 =head1 DESCRIPTION
41
42 Sometimes you don't want a particular attribute to be part of the 
43 serialization, in this case, you want to make sure that attribute 
44 uses this custom meta-attribute. See the SYNOPSIS for a nice example
45 that can be easily cargo-culted.
46
47 =head1 METHODS
48
49 =head2 Introspection
50
51 =over 4
52
53 =item B<meta>
54
55 =back
56
57 =head1 BUGS
58
59 All complex software has bugs lurking in it, and this module is no 
60 exception. If you find a bug please either email me, or add the bug
61 to cpan-RT.
62
63 =head1 AUTHOR
64
65 Chris Prather E<lt>chris.prather@iinteractive.comE<gt>
66
67 Stevan Little E<lt>stevan.little@iinteractive.comE<gt>
68
69 =head1 COPYRIGHT AND LICENSE
70
71 Copyright 2007 by Infinity Interactive, Inc.
72
73 L<http://www.iinteractive.com>
74
75 This library is free software; you can redistribute it and/or modify
76 it under the same terms as Perl itself.
77
78 =cut