line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
# ABSTRACT: DAO request role - `filter` |
2
|
|
|
|
|
|
|
package PONAPI::DAO::Request::Role::HasFilter; |
3
|
|
|
|
|
|
|
|
4
|
8
|
|
|
8
|
|
5620
|
use Moose::Role; |
|
8
|
|
|
|
|
20
|
|
|
8
|
|
|
|
|
60
|
|
5
|
|
|
|
|
|
|
|
6
|
|
|
|
|
|
|
has filter => ( |
7
|
|
|
|
|
|
|
traits => [ 'Hash' ], |
8
|
|
|
|
|
|
|
is => 'ro', |
9
|
|
|
|
|
|
|
isa => 'HashRef', |
10
|
|
|
|
|
|
|
default => sub { +{} }, |
11
|
|
|
|
|
|
|
handles => { |
12
|
|
|
|
|
|
|
"has_filter" => 'count', |
13
|
|
|
|
|
|
|
}, |
14
|
|
|
|
|
|
|
); |
15
|
|
|
|
|
|
|
|
16
|
|
|
|
|
|
|
sub _validate_filter { |
17
|
3
|
|
|
3
|
|
146
|
my $self = shift; |
18
|
|
|
|
|
|
|
|
19
|
3
|
100
|
|
|
|
180
|
$self->has_filter |
20
|
|
|
|
|
|
|
or $self->_bad_request( "`filter` is missing values" ); |
21
|
|
|
|
|
|
|
|
22
|
3
|
|
|
|
|
9
|
return; |
23
|
|
|
|
|
|
|
} |
24
|
|
|
|
|
|
|
|
25
|
8
|
|
|
8
|
|
41787
|
no Moose::Role; 1; |
|
8
|
|
|
|
|
22
|
|
|
8
|
|
|
|
|
40
|
|
26
|
|
|
|
|
|
|
|
27
|
|
|
|
|
|
|
__END__ |
28
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
=pod |
30
|
|
|
|
|
|
|
|
31
|
|
|
|
|
|
|
=encoding UTF-8 |
32
|
|
|
|
|
|
|
|
33
|
|
|
|
|
|
|
=head1 NAME |
34
|
|
|
|
|
|
|
|
35
|
|
|
|
|
|
|
PONAPI::DAO::Request::Role::HasFilter - DAO request role - `filter` |
36
|
|
|
|
|
|
|
|
37
|
|
|
|
|
|
|
=head1 VERSION |
38
|
|
|
|
|
|
|
|
39
|
|
|
|
|
|
|
version 0.002006 |
40
|
|
|
|
|
|
|
|
41
|
|
|
|
|
|
|
=head1 AUTHORS |
42
|
|
|
|
|
|
|
|
43
|
|
|
|
|
|
|
=over 4 |
44
|
|
|
|
|
|
|
|
45
|
|
|
|
|
|
|
=item * |
46
|
|
|
|
|
|
|
|
47
|
|
|
|
|
|
|
Mickey Nasriachi <mickey@cpan.org> |
48
|
|
|
|
|
|
|
|
49
|
|
|
|
|
|
|
=item * |
50
|
|
|
|
|
|
|
|
51
|
|
|
|
|
|
|
Stevan Little <stevan@cpan.org> |
52
|
|
|
|
|
|
|
|
53
|
|
|
|
|
|
|
=item * |
54
|
|
|
|
|
|
|
|
55
|
|
|
|
|
|
|
Brian Fraser <hugmeir@cpan.org> |
56
|
|
|
|
|
|
|
|
57
|
|
|
|
|
|
|
=back |
58
|
|
|
|
|
|
|
|
59
|
|
|
|
|
|
|
=head1 COPYRIGHT AND LICENSE |
60
|
|
|
|
|
|
|
|
61
|
|
|
|
|
|
|
This software is copyright (c) 2016 by Mickey Nasriachi, Stevan Little, Brian Fraser. |
62
|
|
|
|
|
|
|
|
63
|
|
|
|
|
|
|
This is free software; you can redistribute it and/or modify it under |
64
|
|
|
|
|
|
|
the same terms as the Perl 5 programming language system itself. |
65
|
|
|
|
|
|
|
|
66
|
|
|
|
|
|
|
=cut |