1 | <?php |
||
5 | class NetworkFactory |
||
6 | { |
||
7 | /** |
||
8 | * @param string $address |
||
9 | * @param string $p2sh |
||
10 | * @param string $privateKey |
||
11 | * @param bool $testnet |
||
12 | * @return Network |
||
13 | * @throws \Exception |
||
14 | */ |
||
15 | 300 | public static function create($address, $p2sh, $privateKey, $testnet = false) |
|
19 | |||
20 | /** |
||
21 | * @return NetworkInterface |
||
22 | * @throws \Exception |
||
23 | */ |
||
24 | 186 | public static function bitcoin() |
|
33 | 186 | ||
34 | /** |
||
35 | * @return NetworkInterface |
||
36 | * @throws \Exception |
||
37 | */ |
||
38 | public static function bitcoinTestnet() |
||
47 | 30 | ||
48 | /** |
||
49 | 30 | * @return NetworkInterface |
|
50 | * @throws \Exception |
||
51 | */ |
||
52 | public static function bitcoinRegtest() |
||
61 | |||
62 | /** |
||
63 | * @return NetworkInterface |
||
64 | */ |
||
65 | public static function bitcoinSegnet() |
||
74 | 6 | ||
75 | /** |
||
76 | 6 | * @return NetworkInterface |
|
77 | * @throws \Exception |
||
78 | */ |
||
79 | public static function litecoin() |
||
88 | 6 | ||
89 | /** |
||
90 | 6 | * @return NetworkInterface |
|
91 | * @throws \Exception |
||
92 | */ |
||
93 | public static function litecoinTestnet() |
||
102 | 12 | ||
103 | 6 | /** |
|
104 | * @return NetworkInterface |
||
105 | 12 | * @throws \Exception |
|
106 | */ |
||
107 | public static function viacoin() |
||
117 | 6 | ||
118 | 3 | /** |
|
119 | * @return NetworkInterface |
||
120 | 6 | * @throws \Exception |
|
121 | */ |
||
122 | public static function viacoinTestnet() |
||
132 | 6 | ||
133 | /** |
||
134 | 6 | * @return NetworkInterface |
|
135 | * @throws \Exception |
||
136 | */ |
||
137 | public static function dogecoin() |
||
146 | 6 | ||
147 | /** |
||
148 | 6 | * @return NetworkInterface |
|
149 | * @throws \Exception |
||
150 | */ |
||
151 | public static function dogecoinTestnet() |
||
160 | |||
161 | /** |
||
162 | * @return NetworkInterface |
||
163 | * @throws \Exception |
||
164 | */ |
||
165 | public static function startcoin() |
||
174 | |||
175 | /** |
||
176 | * @return NetworkInterface |
||
177 | * @throws \Exception |
||
178 | */ |
||
179 | public static function startcoinTestnet() |
||
188 | 6 | ||
189 | /** |
||
190 | 6 | * @return NetworkInterface |
|
191 | * @throws \Exception |
||
192 | */ |
||
193 | public static function dash() |
||
202 | 6 | ||
203 | 6 | ||
204 | /** |
||
205 | 6 | * @return NetworkInterface |
|
206 | * @throws \Exception |
||
207 | */ |
||
208 | public static function dashTestnet() |
||
217 | } |
||
218 |