Package monero.wallet.model
Class MoneroWalletListener
java.lang.Object
monero.wallet.model.MoneroWalletListener
- All Implemented Interfaces:
MoneroWalletListenerI
Default wallet listener which takes no action on notifications.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidonBalancesChanged(BigInteger newBalance, BigInteger newUnlockedBalance) Invoked when the wallet's balances change.voidonNewBlock(long height) Invoked when a new block is added to the chain.voidonOutputReceived(MoneroOutputWallet output) Invoked 3 times per received output: once when unconfirmed, once when confirmed, and once when unlocked.voidonOutputSpent(MoneroOutputWallet output) Invoked twice per spent output: once when confirmed and once when unlocked.voidonSyncProgress(long height, long startHeight, long endHeight, double percentDone, String message) Invoked as the wallet is synchronized.
-
Constructor Details
-
MoneroWalletListener
public MoneroWalletListener()
-
-
Method Details
-
onSyncProgress
public void onSyncProgress(long height, long startHeight, long endHeight, double percentDone, String message) Description copied from interface:MoneroWalletListenerIInvoked as the wallet is synchronized.- Specified by:
onSyncProgressin interfaceMoneroWalletListenerI- Parameters:
height- - height of the synced blockstartHeight- - starting height of the sync requestendHeight- - ending height of the sync requestpercentDone- - sync progress as a percentagemessage- is a human-readable description of the current progress
-
onNewBlock
public void onNewBlock(long height) Description copied from interface:MoneroWalletListenerIInvoked when a new block is added to the chain.- Specified by:
onNewBlockin interfaceMoneroWalletListenerI- Parameters:
height- - the height of the new block (i.e. the number of blocks before it).
-
onBalancesChanged
Description copied from interface:MoneroWalletListenerIInvoked when the wallet's balances change.- Specified by:
onBalancesChangedin interfaceMoneroWalletListenerI- Parameters:
newBalance- - new wallet balancenewUnlockedBalance- - new unlocked wallet balance
-
onOutputReceived
Description copied from interface:MoneroWalletListenerIInvoked 3 times per received output: once when unconfirmed, once when confirmed, and once when unlocked.- Specified by:
onOutputReceivedin interfaceMoneroWalletListenerI- Parameters:
output- - the received output
-
onOutputSpent
Description copied from interface:MoneroWalletListenerIInvoked twice per spent output: once when confirmed and once when unlocked.- Specified by:
onOutputSpentin interfaceMoneroWalletListenerI- Parameters:
output- - the spent output
-