| 1 | <?php |
||
| 11 | class CompactSignature extends Signature implements CompactSignatureInterface |
||
| 12 | { |
||
| 13 | /** |
||
| 14 | * @var EcAdapter |
||
| 15 | */ |
||
| 16 | private $ecAdapter; |
||
|
|
|||
| 17 | |||
| 18 | /** |
||
| 19 | * @var int|string |
||
| 20 | */ |
||
| 21 | private $recid; |
||
| 22 | |||
| 23 | /** |
||
| 24 | * @var bool |
||
| 25 | */ |
||
| 26 | private $compressed; |
||
| 27 | |||
| 28 | /** |
||
| 29 | * @param EcAdapter $adapter |
||
| 30 | * @param \GMP $r |
||
| 31 | * @param \GMP $s |
||
| 32 | * @param int $recid |
||
| 33 | * @param bool $compressed |
||
| 34 | */ |
||
| 35 | 8 | public function __construct(EcAdapter $adapter, \GMP $r, \GMP $s, int $recid, bool $compressed) |
|
| 42 | |||
| 43 | /** |
||
| 44 | * @return Signature |
||
| 45 | */ |
||
| 46 | 7 | public function convert(): Signature |
|
| 50 | |||
| 51 | /** |
||
| 52 | * @return int |
||
| 53 | */ |
||
| 54 | 7 | public function getRecoveryId(): int |
|
| 58 | |||
| 59 | /** |
||
| 60 | * @return bool |
||
| 61 | */ |
||
| 62 | 7 | public function isCompressed(): bool |
|
| 66 | |||
| 67 | /** |
||
| 68 | * @return int |
||
| 69 | */ |
||
| 70 | 5 | public function getFlags(): int |
|
| 74 | |||
| 75 | /** |
||
| 76 | * @return BufferInterface |
||
| 77 | */ |
||
| 78 | 5 | public function getBuffer(): BufferInterface |
|
| 82 | } |
||
| 83 |