From 0947ea10c81b3e4b8da82adab2410f33f0a77cd2 Mon Sep 17 00:00:00 2001 From: zeroleak Date: Fri, 27 Aug 2021 09:30:11 +0200 Subject: [PATCH] upgrade to whirlpool-client 0.23.30-early4 + extlibj 0.0.19-dsk3 --- .../drongo/wallet/UtxoMixData.java | 18 ++++++------------ .../sparrowwallet/drongo/wallet/Wallet.java | 6 +++++- 2 files changed, 11 insertions(+), 13 deletions(-) diff --git a/src/main/java/com/sparrowwallet/drongo/wallet/UtxoMixData.java b/src/main/java/com/sparrowwallet/drongo/wallet/UtxoMixData.java index 07eaf10..1bf8764 100644 --- a/src/main/java/com/sparrowwallet/drongo/wallet/UtxoMixData.java +++ b/src/main/java/com/sparrowwallet/drongo/wallet/UtxoMixData.java @@ -1,30 +1,24 @@ package com.sparrowwallet.drongo.wallet; public class UtxoMixData extends Persistable { - private final String poolId; private final int mixesDone; - private final Long forwarding; + private final Long expired; - public UtxoMixData(String poolId, int mixesDone, Long forwarding) { - this.poolId = poolId; + public UtxoMixData(int mixesDone, Long expired) { this.mixesDone = mixesDone; - this.forwarding = forwarding; - } - - public String getPoolId() { - return poolId; + this.expired = expired; } public int getMixesDone() { return mixesDone; } - public Long getForwarding() { - return forwarding; + public Long getExpired() { + return expired; } @Override public String toString() { - return "{poolId:" + poolId + ", mixesDone:" + mixesDone + ", forwarding:" + forwarding + "}"; + return "{mixesDone:" + mixesDone + ", expired: " + expired + "}"; } } diff --git a/src/main/java/com/sparrowwallet/drongo/wallet/Wallet.java b/src/main/java/com/sparrowwallet/drongo/wallet/Wallet.java index aaf1078..cd6d659 100644 --- a/src/main/java/com/sparrowwallet/drongo/wallet/Wallet.java +++ b/src/main/java/com/sparrowwallet/drongo/wallet/Wallet.java @@ -231,7 +231,11 @@ public class Wallet extends Persistable { } public UtxoMixData getUtxoMixData(BlockTransactionHashIndex utxo) { - return utxoMixes.get(Sha256Hash.of(utxo.toString().getBytes(StandardCharsets.UTF_8))); + return getUtxoMixData(Sha256Hash.of(utxo.toString().getBytes(StandardCharsets.UTF_8))); + } + + public UtxoMixData getUtxoMixData(Sha256Hash utxoKey) { + return utxoMixes.get(utxoKey); } public Map getUtxoMixes() {