Completed
Push — 0.0.35 ( b2fc74...d8d049 )
by thomas
28:12 queued 09:10
created

CheckerCreator   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 13
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 3

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
dl 0
loc 13
ccs 2
cts 2
cp 1
rs 10
c 0
b 0
f 0
wmc 1
lcom 1
cbo 3

1 Method

Rating   Name   Duplication   Size   Complexity  
A create() 0 4 1
1
<?php
2
3
namespace BitWasp\Bitcoin\Transaction\Factory\Checker;
4
5
use BitWasp\Bitcoin\Script\Interpreter\CheckerBase;
6
use BitWasp\Bitcoin\Script\Interpreter\Checker;
7
use BitWasp\Bitcoin\Transaction\TransactionInterface;
8
use BitWasp\Bitcoin\Transaction\TransactionOutputInterface;
9
10
class CheckerCreator extends CheckerCreatorBase
11
{
12
    /**
13
     * @param TransactionInterface $tx
14
     * @param int $nInput
15
     * @param TransactionOutputInterface $txOut
16
     * @return CheckerBase
17
     */
18 60
    public function create(TransactionInterface $tx, $nInput, TransactionOutputInterface $txOut)
19
    {
20 60
        return new Checker($this->ecAdapter, $tx, $nInput, $txOut->getValue(), $this->txSigSerializer, $this->pubKeySerializer);
21
    }
22
}
23