blib/lib/DBIO/Test/MooseSchema/ResultSet/Artist.pm

filter: Statementstmt 33.3% 1 / 3 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 100% 1 / 1 Podpod n/a totaltotal 50.0% 2 / 4 CC 1 SCAR 2.6
CC
1
Cov
33%
BEGIN
1.3
CRAP 1.3
« blib/lib/DBIO/DeploymentHandler/VersionStorage/Standard/VersionResultSet.pm ↑ Summary blib/lib/DBIO/Test/MooseSugarSchema/ResultSet/Artist.pm »
1 package DBIO::Test::MooseSchema::ResultSet::Artist;
2 # ABSTRACT: Custom Moose-based ResultSet for the artist source
3  
4 our $VERSION = '0.900007';
5  
6 0 ▶use Moose;
Subroutine BEGIN: called CC=1 SCAR=2.6
7 use MooseX::NonMoose;
8 extends 'DBIO::ResultSet';
9  
10 # MooseX::NonMoose's default FOREIGNBUILDARGS is a pass-through — correct
11 # for ResultSet: no key filtering needed unlike DBIO::Row::new.
12  
13 # ResultSet-level Moose attribute
14 has default_limit => ( is => 'rw', isa => 'Int', lazy => 1, default => 100 );
15  
16 sub by_name {
17 my ($self, $name) = @_;
18 return $self->search({ name => $name });
19 }
20  
21 sub order_by_name {
22 return $_[0]->search({}, { order_by => { -asc => 'name' } });
23 }
24  
25 __PACKAGE__->meta->make_immutable;
26  
27 1;
28  
29 __END__
« blib/lib/DBIO/DeploymentHandler/VersionStorage/Standard/VersionResultSet.pm ↑ Summary blib/lib/DBIO/Test/MooseSugarSchema/ResultSet/Artist.pm »