1 | <?php |
||
12 | class TransactionInput extends Serializable implements TransactionInputInterface |
||
13 | { |
||
14 | |||
15 | /** |
||
16 | * @var OutPointInterface |
||
17 | */ |
||
18 | private $outPoint; |
||
19 | |||
20 | /** |
||
21 | * @var ScriptInterface |
||
22 | */ |
||
23 | private $script; |
||
24 | |||
25 | /** |
||
26 | * @var string|int |
||
27 | */ |
||
28 | private $sequence; |
||
29 | |||
30 | /** |
||
31 | * @param OutPointInterface $outPoint |
||
32 | * @param ScriptInterface $script |
||
33 | * @param int $sequence |
||
34 | */ |
||
35 | public function __construct(OutPointInterface $outPoint, ScriptInterface $script, $sequence = self::SEQUENCE_FINAL) |
||
41 | 2764 | ||
42 | /** |
||
43 | * @return OutPointInterface |
||
44 | */ |
||
45 | public function getOutPoint() |
||
49 | |||
50 | /** |
||
51 | * @return ScriptInterface |
||
52 | */ |
||
53 | public function getScript() |
||
57 | |||
58 | /** |
||
59 | * @return int |
||
60 | */ |
||
61 | public function getSequence() |
||
65 | |||
66 | /** |
||
67 | * @param TransactionInputInterface $input |
||
68 | * @return bool |
||
69 | */ |
||
70 | 2686 | public function equals(TransactionInputInterface $input) |
|
82 | 12 | ||
83 | /** |
||
84 | * Check whether this transaction is a Coinbase transaction |
||
85 | 48 | * |
|
86 | 6 | * @return boolean |
|
87 | */ |
||
88 | public function isCoinbase() |
||
95 | |||
96 | /** |
||
97 | 12 | * @return bool |
|
98 | */ |
||
99 | 12 | public function isFinal() |
|
104 | |||
105 | /** |
||
106 | * @return BufferInterface |
||
107 | */ |
||
108 | 6 | public function getBuffer() |
|
112 | } |
||
113 |