Java Code Examples for wallettemplate.utils.WTUtils

The following examples show how to use wallettemplate.utils.WTUtils. These examples are extracted from open source projects. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
public void initialize() {
    Coin balance = Main.bitcoin.wallet().getBalance();
    checkState(!balance.isZero());
    new BitcoinAddressValidator(Main.params, address, sendBtn);
    new TextFieldValidator(amountEdit, text ->
            !WTUtils.didThrow(() -> checkState(Coin.parseCoin(text).compareTo(balance) <= 0)));
    amountEdit.setText(balance.toPlainString());
}
 
Example 2
public void initialize () {
    Coin balance = Main.wallet.getBalance();
    checkState(!balance.isZero());
    new BitcoinAddressValidator(Constants.getNetwork(), address, sendBtn);
    new TextFieldValidator(amountEdit, text ->
            !WTUtils.didThrow(() -> checkState(Coin.parseCoin(text).compareTo(balance) <= 0)));
    amountEdit.setText(balance.toPlainString());
}
 
Example 3
public void initialize() {
    Coin balance = Main.bitcoin.wallet().getBalance();
    checkState(!balance.isZero());
    new BitcoinAddressValidator(Main.params, address, sendBtn);
    new TextFieldValidator(amountEdit, text ->
            !WTUtils.didThrow(() -> checkState(Coin.parseCoin(text).compareTo(balance) <= 0)));
    amountEdit.setText(balance.toPlainString());
}
 
Example 4
public void initialize() {
    Coin balance = Main.bitcoin.wallet().getBalance();
    checkState(!balance.isZero());
    new BitcoinAddressValidator(Main.params, address, sendBtn);
    new TextFieldValidator(amountEdit, text ->
            !WTUtils.didThrow(() -> checkState(Coin.parseCoin(text).compareTo(balance) <= 0)));
    amountEdit.setText(balance.toPlainString());
}