line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
13
|
|
|
13
|
|
17028
|
use utf8; |
|
13
|
|
|
|
|
38
|
|
|
13
|
|
|
|
|
91
|
|
2
|
|
|
|
|
|
|
package CPAN::Testers::Schema::ResultSet::PerlVersion; |
3
|
|
|
|
|
|
|
our $VERSION = '0.024'; |
4
|
|
|
|
|
|
|
# ABSTRACT: Query Perl version metadata |
5
|
|
|
|
|
|
|
|
6
|
|
|
|
|
|
|
#pod =head1 SYNOPSIS |
7
|
|
|
|
|
|
|
#pod |
8
|
|
|
|
|
|
|
#pod my $rs = $schema->resultset( 'PerlVersion' ); |
9
|
|
|
|
|
|
|
#pod $rs->find_or_create({ version => '5.27.0' }); |
10
|
|
|
|
|
|
|
#pod |
11
|
|
|
|
|
|
|
#pod $rs = $rs->maturity( 'stable' ); # or 'dev' |
12
|
|
|
|
|
|
|
#pod |
13
|
|
|
|
|
|
|
#pod =head1 DESCRIPTION |
14
|
|
|
|
|
|
|
#pod |
15
|
|
|
|
|
|
|
#pod This object helps to query Perl version metadata. |
16
|
|
|
|
|
|
|
#pod |
17
|
|
|
|
|
|
|
#pod =head1 SEE ALSO |
18
|
|
|
|
|
|
|
#pod |
19
|
|
|
|
|
|
|
#pod L<CPAN::Testers::Schema::Result::PerlVersion>, L<DBIx::Class::ResultSet>, |
20
|
|
|
|
|
|
|
#pod L<CPAN::Testers::Schema> |
21
|
|
|
|
|
|
|
#pod |
22
|
|
|
|
|
|
|
#pod =cut |
23
|
|
|
|
|
|
|
|
24
|
13
|
|
|
13
|
|
857
|
use CPAN::Testers::Schema::Base 'ResultSet'; |
|
13
|
|
|
|
|
83
|
|
|
13
|
|
|
|
|
121
|
|
25
|
13
|
|
|
13
|
|
5168
|
use Log::Any '$LOG'; |
|
13
|
|
|
|
|
83828
|
|
|
13
|
|
|
|
|
72
|
|
26
|
13
|
|
|
13
|
|
22265
|
use Carp (); |
|
13
|
|
|
|
|
102
|
|
|
13
|
|
|
|
|
2216
|
|
27
|
|
|
|
|
|
|
|
28
|
|
|
|
|
|
|
#pod =method maturity |
29
|
|
|
|
|
|
|
#pod |
30
|
|
|
|
|
|
|
#pod Filter Perl versions of the given maturity. One of C<stable> or C<dev>. |
31
|
|
|
|
|
|
|
#pod |
32
|
|
|
|
|
|
|
#pod =cut |
33
|
|
|
|
|
|
|
|
34
|
2
|
|
|
2
|
1
|
7019
|
sub maturity( $self, $maturity ) { |
|
2
|
|
|
|
|
5
|
|
|
2
|
|
|
|
|
5
|
|
|
2
|
|
|
|
|
4
|
|
35
|
2
|
100
|
|
|
|
11
|
if ( $maturity eq 'stable' ) { |
|
|
50
|
|
|
|
|
|
36
|
1
|
|
|
|
|
5
|
return $self->search({ devel => 0 }); |
37
|
|
|
|
|
|
|
} |
38
|
|
|
|
|
|
|
elsif ( $maturity eq 'dev' ) { |
39
|
1
|
|
|
|
|
6
|
return $self->search({ devel => 1 }); |
40
|
|
|
|
|
|
|
} |
41
|
0
|
|
|
|
|
|
Carp::croak "Unknown maturity: $maturity. Must be one of: 'stable', 'dev'"; |
42
|
|
|
|
|
|
|
} |
43
|
|
|
|
|
|
|
|
44
|
|
|
|
|
|
|
|
45
|
|
|
|
|
|
|
1; |
46
|
|
|
|
|
|
|
|
47
|
|
|
|
|
|
|
__END__ |
48
|
|
|
|
|
|
|
|
49
|
|
|
|
|
|
|
=pod |
50
|
|
|
|
|
|
|
|
51
|
|
|
|
|
|
|
=head1 NAME |
52
|
|
|
|
|
|
|
|
53
|
|
|
|
|
|
|
CPAN::Testers::Schema::ResultSet::PerlVersion - Query Perl version metadata |
54
|
|
|
|
|
|
|
|
55
|
|
|
|
|
|
|
=head1 VERSION |
56
|
|
|
|
|
|
|
|
57
|
|
|
|
|
|
|
version 0.024 |
58
|
|
|
|
|
|
|
|
59
|
|
|
|
|
|
|
=head1 SYNOPSIS |
60
|
|
|
|
|
|
|
|
61
|
|
|
|
|
|
|
my $rs = $schema->resultset( 'PerlVersion' ); |
62
|
|
|
|
|
|
|
$rs->find_or_create({ version => '5.27.0' }); |
63
|
|
|
|
|
|
|
|
64
|
|
|
|
|
|
|
$rs = $rs->maturity( 'stable' ); # or 'dev' |
65
|
|
|
|
|
|
|
|
66
|
|
|
|
|
|
|
=head1 DESCRIPTION |
67
|
|
|
|
|
|
|
|
68
|
|
|
|
|
|
|
This object helps to query Perl version metadata. |
69
|
|
|
|
|
|
|
|
70
|
|
|
|
|
|
|
=head1 METHODS |
71
|
|
|
|
|
|
|
|
72
|
|
|
|
|
|
|
=head2 maturity |
73
|
|
|
|
|
|
|
|
74
|
|
|
|
|
|
|
Filter Perl versions of the given maturity. One of C<stable> or C<dev>. |
75
|
|
|
|
|
|
|
|
76
|
|
|
|
|
|
|
=head1 SEE ALSO |
77
|
|
|
|
|
|
|
|
78
|
|
|
|
|
|
|
L<CPAN::Testers::Schema::Result::PerlVersion>, L<DBIx::Class::ResultSet>, |
79
|
|
|
|
|
|
|
L<CPAN::Testers::Schema> |
80
|
|
|
|
|
|
|
|
81
|
|
|
|
|
|
|
=head1 AUTHORS |
82
|
|
|
|
|
|
|
|
83
|
|
|
|
|
|
|
=over 4 |
84
|
|
|
|
|
|
|
|
85
|
|
|
|
|
|
|
=item * |
86
|
|
|
|
|
|
|
|
87
|
|
|
|
|
|
|
Oriol Soriano <oriolsoriano@gmail.com> |
88
|
|
|
|
|
|
|
|
89
|
|
|
|
|
|
|
=item * |
90
|
|
|
|
|
|
|
|
91
|
|
|
|
|
|
|
Doug Bell <preaction@cpan.org> |
92
|
|
|
|
|
|
|
|
93
|
|
|
|
|
|
|
=back |
94
|
|
|
|
|
|
|
|
95
|
|
|
|
|
|
|
=head1 COPYRIGHT AND LICENSE |
96
|
|
|
|
|
|
|
|
97
|
|
|
|
|
|
|
This software is copyright (c) 2018 by Oriol Soriano, Doug Bell. |
98
|
|
|
|
|
|
|
|
99
|
|
|
|
|
|
|
This is free software; you can redistribute it and/or modify it under |
100
|
|
|
|
|
|
|
the same terms as the Perl 5 programming language system itself. |
101
|
|
|
|
|
|
|
|
102
|
|
|
|
|
|
|
=cut |