Skip to content

Commit d402bb2

Browse files
committed
fix: add new methods to epiccash template
1 parent e81816e commit d402bb2

File tree

1 file changed

+44
-3
lines changed

1 file changed

+44
-3
lines changed

tool/wl_templates/EPIC_libepiccash_interface_impl.template.dart

Lines changed: 44 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,14 +30,37 @@ final class _LibEpicCashInterfaceImpl extends LibEpicCashInterface {
3030
}
3131

3232
@override
33-
Future<({String commitId, String slateId})> createTransaction({
33+
Future<({String slateId, String commitId, String slateJson})> txReceive({
34+
required String wallet,
35+
required String slateJson,
36+
}) {
37+
return LibEpiccash.txReceive(
38+
wallet: wallet,
39+
slateJson: slateJson,
40+
);
41+
}
42+
43+
@override
44+
Future<({String slateId, String commitId})> txFinalize({
45+
required String wallet,
46+
required String slateJson,
47+
}) {
48+
return LibEpiccash.txFinalize(
49+
wallet: wallet,
50+
slateJson: slateJson,
51+
);
52+
}
53+
54+
@override
55+
Future<({String commitId, String slateId, String slateJson})> createTransaction({
3456
required String wallet,
3557
required int amount,
3658
required String address,
3759
required int secretKeyIndex,
3860
required String epicboxConfig,
3961
required int minimumConfirmations,
4062
required String note,
63+
bool returnSlate = false,
4164
}) {
4265
return LibEpiccash.createTransaction(
4366
wallet: wallet,
@@ -47,6 +70,7 @@ final class _LibEpicCashInterfaceImpl extends LibEpicCashInterface {
4770
epicboxConfig: epicboxConfig,
4871
minimumConfirmations: minimumConfirmations,
4972
note: note,
73+
returnSlate: returnSlate,
5074
);
5175
}
5276

@@ -210,18 +234,35 @@ final class _LibEpicCashInterfaceImpl extends LibEpicCashInterface {
210234

211235
@override
212236
void startEpicboxListener({
237+
required String walletId,
213238
required String wallet,
214239
required String epicboxConfig,
215240
}) {
216241
return LibEpiccash.startEpicboxListener(
242+
walletId: walletId,
217243
wallet: wallet,
218244
epicboxConfig: epicboxConfig,
219245
);
220246
}
221247

222248
@override
223-
void stopEpicboxListener() {
224-
return LibEpiccash.stopEpicboxListener();
249+
void stopEpicboxListener({required String walletId}) {
250+
return LibEpiccash.stopEpicboxListener(walletId: walletId);
251+
}
252+
253+
@override
254+
void stopAllEpicboxListeners() {
255+
return LibEpiccash.stopAllEpicboxListeners();
256+
}
257+
258+
@override
259+
bool isEpicboxListenerRunning({required String walletId}) {
260+
return LibEpiccash.isEpicboxListenerRunning(walletId: walletId);
261+
}
262+
263+
@override
264+
List<String> getActiveListenerWalletIds() {
265+
return LibEpiccash.getActiveListenerWalletIds();
225266
}
226267

227268
@override

0 commit comments

Comments
 (0)