| 1 | # ABSTRACT: document builder - role - meta | ||
| 2 | package PONAPI::Document::Builder::Role::HasMeta; | ||
| 3 | |||
| 4 | 27 | ▶ | use Moose::Role; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 5 | |||
| 6 | has _meta => ( | ||
| 7 | init_arg => undef, | ||
| 8 | traits => [ 'Hash' ], | ||
| 9 | is => 'ro', | ||
| 10 | isa => 'HashRef', | ||
| 11 | 124 | ▶ | default => sub { +{} }, |
|
Subroutine
__ANON__: called CC=1 SCAR=0.0
| |||
| 12 | 27 | handles => { | |
| 13 | has_meta => 'count', | ||
| 14 | } | ||
| 15 | ); | ||
| 16 | |||
| 17 | sub add_meta { | ||
| 18 | 12 | ▶ | my ($self, %args) = @_; |
|
Subroutine
add_meta: called CC=1 SCAR=0.0
Pod
undocumented
| |||
| 19 | 12 | @{ $self->_meta }{ keys %args } = values %args; | |
| 20 | 12 | return $self; | |
| 21 | } | ||
| 22 | |||
| 23 | 27 | ▶ | no Moose::Role; 1; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 24 | |||
| 25 | __END__ | ||
| 26 | |||
| 27 | =pod | ||
| 28 | |||
| 29 | =encoding UTF-8 | ||
| 30 | |||
| 31 | =head1 NAME | ||
| 32 | |||
| 33 | PONAPI::Document::Builder::Role::HasMeta - document builder - role - meta | ||
| 34 | |||
| 35 | =head1 VERSION | ||
| 36 | |||
| 37 | version 0.001001 | ||
| 38 | |||
| 39 | =head1 AUTHORS | ||
| 40 | |||
| 41 | =over 4 | ||
| 42 | |||
| 43 | =item * | ||
| 44 | |||
| 45 | Mickey Nasriachi <mickey@cpan.org> | ||
| 46 | |||
| 47 | =item * | ||
| 48 | |||
| 49 | Stevan Little <stevan@cpan.org> | ||
| 50 | |||
| 51 | =item * | ||
| 52 | |||
| 53 | Brian Fraser <hugmeir@cpan.org> | ||
| 54 | |||
| 55 | =back | ||
| 56 | |||
| 57 | =head1 COPYRIGHT AND LICENSE | ||
| 58 | |||
| 59 | This software is copyright (c) 2016 by Mickey Nasriachi, Stevan Little, Brian Fraser. | ||
| 60 | |||
| 61 | This is free software; you can redistribute it and/or modify it under | ||
| 62 | the same terms as the Perl 5 programming language system itself. | ||
| 63 | |||
| 64 | =cut | ||