File Coverage

blib/lib/Database/Async/ORM/Type.pm
Criterion Covered Total %
statement 8 18 44.4
branch 0 2 0.0
condition 0 4 0.0
subroutine 3 13 23.0
pod 0 11 0.0
total 11 48 22.9


line stmt bran cond sub pod time code
1             package Database::Async::ORM::Type;
2              
3 3     3   271296 use strict;
  3         7  
  3         101  
4 3     3   14 use warnings;
  3         4  
  3         990  
5              
6             our $VERSION = '0.019'; # VERSION
7              
8             sub new {
9 584     584 0 1340 my ($class, %args) = @_;
10 584         2122 bless \%args, $class
11             }
12              
13 0     0 0   sub schema { shift->{schema} }
14 0     0 0   sub description { shift->{description} }
15 0     0 0   sub defined_in { shift->{defined_in} }
16 0     0 0   sub type { shift->{type} }
17 0     0 0   sub name { shift->{name} }
18 0     0 0   sub basis { shift->{basis} }
19 0     0 0   sub is_builtin { shift->{is_builtin} }
20 0   0 0 0   sub values : method { (shift->{values} // [])->@* }
21 0   0 0 0   sub fields { (shift->{fields} // [])->@* }
22              
23 0 0   0 0   sub qualified_name { ($_[0]->is_builtin ? $_[0]->name : $_[0]->schema->name . '.' . $_[0]->name) }
24              
25             1;
26