| 1 | <?php |
||
| 8 | class NetworkParams |
||
| 9 | { |
||
| 10 | /** |
||
| 11 | * @var NetworkInterface |
||
| 12 | */ |
||
| 13 | private $network; |
||
| 14 | |||
| 15 | /** |
||
| 16 | * @var string |
||
| 17 | */ |
||
| 18 | private $name; |
||
| 19 | |||
| 20 | /** |
||
| 21 | * @var bool |
||
| 22 | */ |
||
| 23 | private $testnet; |
||
| 24 | |||
| 25 | /** |
||
| 26 | * @var string |
||
| 27 | */ |
||
| 28 | private $shortCode; |
||
| 29 | |||
| 30 | /** |
||
| 31 | * NetworkParams constructor. |
||
| 32 | * @param NetworkInterface $network |
||
| 33 | * @param string $name |
||
| 34 | * @param string $shortCode |
||
| 35 | * @param bool $testnet |
||
| 36 | */ |
||
| 37 | 93 | public function __construct($shortCode, $name, $testnet, NetworkInterface $network) { |
|
| 43 | |||
| 44 | /** |
||
| 45 | * @return string |
||
| 46 | */ |
||
| 47 | 1 | public function getName() { |
|
| 50 | |||
| 51 | /** |
||
| 52 | * @return string |
||
| 53 | */ |
||
| 54 | 1 | public function getShortCode() { |
|
| 57 | |||
| 58 | /** |
||
| 59 | * @param $network |
||
| 60 | * @return bool |
||
| 61 | */ |
||
| 62 | 93 | public function isNetwork($network) { |
|
| 65 | |||
| 66 | /** |
||
| 67 | * @return bool |
||
| 68 | */ |
||
| 69 | 1 | public function isTestnet() { |
|
| 72 | |||
| 73 | /** |
||
| 74 | * @return NetworkInterface |
||
| 75 | */ |
||
| 76 | 23 | public function getNetwork() { |
|
| 79 | } |
||
| 80 |