add wallet watchLast field

This commit is contained in:
Craig Raw 2022-01-19 13:48:20 +02:00
parent 34bd72d87a
commit 8dca2ee3f0
2 changed files with 14 additions and 0 deletions

View file

@ -41,6 +41,7 @@ public class Wallet extends Persistable implements Comparable<Wallet> {
private final Map<Sha256Hash, UtxoMixData> utxoMixes = new HashMap<>();
private Integer storedBlockHeight;
private Integer gapLimit;
private Integer watchLast;
private Date birthDate;
public Wallet() {
@ -339,6 +340,14 @@ public class Wallet extends Persistable implements Comparable<Wallet> {
this.gapLimit = gapLimit;
}
public Integer getWatchLast() {
return watchLast;
}
public void setWatchLast(Integer watchLast) {
this.watchLast = watchLast;
}
public Date getBirthDate() {
return birthDate;
}
@ -1463,6 +1472,7 @@ public class Wallet extends Persistable implements Comparable<Wallet> {
}
copy.setStoredBlockHeight(getStoredBlockHeight());
copy.gapLimit = gapLimit;
copy.watchLast = watchLast;
copy.birthDate = birthDate;
return copy;

View file

@ -94,6 +94,10 @@ public class WalletNode extends Persistable implements Comparable<WalletNode> {
this.children = children;
}
public boolean isUsed() {
return !transactionOutputs.isEmpty();
}
public Set<BlockTransactionHashIndex> getTransactionOutputs() {
return transactionOutputs;
}