Search in sources :

Example 1 with WhirlpoolTx0

use of com.samourai.wallet.whirlpool.WhirlpoolTx0 in project samourai-wallet-android by Samourai-Wallet.

the class PoolViewModel method setMinerFee.

public void setMinerFee(Long minerFee, List<UTXOCoin> coins) {
    this.minerFee = minerFee;
    try {
        this.tx0 = new WhirlpoolTx0(this.getDenomination(), minerFee / 1000L, 0, coins);
        // tx0.make();
        this.totalMinerFee = tx0.getFee();
        this.totalEstimatedBytes = tx0.getEstimatedBytes();
    } catch (Exception ex) {
        ex.printStackTrace();
    }
}
Also used : WhirlpoolTx0(com.samourai.wallet.whirlpool.WhirlpoolTx0)

Example 2 with WhirlpoolTx0

use of com.samourai.wallet.whirlpool.WhirlpoolTx0 in project samourai-wallet-android by Samourai-Wallet.

the class NewPoolActivity method calculateTx0.

private void calculateTx0(long denomination, long fee) {
    tx0 = new WhirlpoolTx0(denomination, fee, 0, selectedCoins);
    LogUtil.info(TAG, "calculateTx0: ".concat(String.valueOf(denomination)).concat(" fee").concat(String.valueOf(fee)));
    try {
        tx0.make();
    } catch (Exception ex) {
        Toast.makeText(this, ex.getMessage(), Toast.LENGTH_LONG).show();
        ex.printStackTrace();
        return;
    }
    if (tx0.getTx0() != null) {
        enableConfirmButton(true);
        selectPoolFragment.setTX0(selectedCoins);
    } else {
        enableConfirmButton(false);
    }
}
Also used : WhirlpoolTx0(com.samourai.wallet.whirlpool.WhirlpoolTx0)

Aggregations

WhirlpoolTx0 (com.samourai.wallet.whirlpool.WhirlpoolTx0)2