lib/Finance/Dogechain/Address.pm

filter: Statementstmt 50.0% 6 / 12 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 16.6% 1 / 6 Podpod 100% 5 / 5 totaltotal 52.1% 12 / 23 SCAR 1.2
CC
1
Cov
50%
balance
2.0
received
2.0
sent
2.0
CRAP 1.1
« blib/lib/Finance/Dogechain/Address.pm ↑ Summary lib/Finance/Dogechain.pm »
1 package Finance::Dogechain::Address;
2 1 $Finance::Dogechain::Address::VERSION = '1.20210418.2306';
3 1 ▶use Mojo::Base -base, -signatures, 'Finance::Dogechain::Base';
Subroutine BEGIN: called CC=1 SCAR=0.0
4  
5 1 has 'address';
6  
7 ▶sub balance($self) {
Subroutine balance: not called CC=1 SCAR=6.9
Pod documented
8 0 return $self->return_field_if_success( '/address/balance/' . $self->address, 'balance' );
9 }
10  
11 ▶sub received($self) {
Subroutine received: not called CC=1 SCAR=6.9
Pod documented
12 0 return $self->return_field_if_success( '/address/received/' . $self->address, 'received' );
13 }
14  
15 ▶sub sent($self) {
Subroutine sent: not called CC=1 SCAR=6.9
Pod documented
16 0 return $self->return_field_if_success( '/address/sent' . $self->address, 'sent' );
17 }
18  
19 ▶sub unspent($self) {
Subroutine unspent: not called CC=1 SCAR=6.9
Pod documented
20 return [
21 map {
22 0 $_->{value} / 100000000;
23 }
24 $self->return_field_if_success( '/unspent/' . $self->address, 'unspent_outputs' )->@*
25 ];
26 }
27  
28 ▶sub TO_JSON($self) {
Subroutine TO_JSON: not called CC=1 SCAR=6.9
Pod documented
29 0 return '[Finance::Dogechain::Address](address => ' . $self->address . ')';
30 }
31  
32 1 'to the moon';
33 __END__
« blib/lib/Finance/Dogechain/Address.pm ↑ Summary lib/Finance/Dogechain.pm »