1MooseX::Types::JSON(3)User Contributed Perl DocumentationMooseX::Types::JSON(3)
2
3
4
6 MooseX::Types::JSON - JSON datatype for Moose
7
9 package Foo;
10
11 use Moose;
12 use Moose::Util::TypeConstraints;
13 use MooseX::Types::JSON qw( JSON );
14
15 has config => ( is => 'rw', isa => JSON );
16 has options => ( is => 'rw', isa => relaxedJSON );
17
18 String type constraints that match valid and relaxed JSON. For the
19 meaning of 'relaxed' see JSON. All the heavy lifting in the background
20 is also done by JSON.
21
22 Coercions from Defined types are included.
23
24 · JSON
25
26 A Str that is valid JSON.
27
28 · relaxedJSON
29
30 A Str that is 'relaxed' JSON. For the meaning of 'relaxed' see
31 JSON.
32
34 Steve Huff
35
37 Michael Langner
38
40 If you'd like to contribute, just fork my repository
41 (<http://github.com/cpan-mila/perl-moosex-types-json>) on Github,
42 commit your changes and send me a pull request.
43
45 Please report any bugs or feature requests at
46 <http://github.com/cpan-mila/perl-moosex-types-json/issues>.
47
49 Copyright 2014 Michael Langner, all rights reserved.
50
51 This program is free software; you can redistribute it and/or modify it
52 under the same terms as Perl itself.
53
54
55
56perl v5.28.0 2014-08-22 MooseX::Types::JSON(3)