@Override public String toString() { return "MoneroWithdrawFundsParams{" + "address='" + getAddress() + '\'' + ", paymentId='" + getPaymentId() + '\'' + ", currency=" + getCurrency() + ", amount=" + getAmount() + ", commission=" + getCommission() + '}'; }
@Override public String withdrawFunds(WithdrawFundsParams params) throws IOException { if (params instanceof MoneroWithdrawFundsParams) { MoneroWithdrawFundsParams moneroWithdrawFundsParams = (MoneroWithdrawFundsParams) params; return withdrawFundsRaw( moneroWithdrawFundsParams.getCurrency(), moneroWithdrawFundsParams.getAmount(), moneroWithdrawFundsParams.getAddress(), moneroWithdrawFundsParams.getPaymentId()); } else if (params instanceof RippleWithdrawFundsParams) { RippleWithdrawFundsParams rippleWithdrawFundsParams = (RippleWithdrawFundsParams) params; return withdrawFundsRaw( rippleWithdrawFundsParams.getCurrency(), rippleWithdrawFundsParams.getAmount(), rippleWithdrawFundsParams.getAddress(), rippleWithdrawFundsParams.getTag()); } else if (params instanceof DefaultWithdrawFundsParams) { DefaultWithdrawFundsParams defaultParams = (DefaultWithdrawFundsParams) params; return withdrawFundsRaw( defaultParams.getCurrency(), defaultParams.getAmount(), defaultParams.getAddress(), null); } throw new IllegalStateException("Don't know how to withdraw: " + params); }
@Override public String withdrawFunds(WithdrawFundsParams params) throws IOException { if (params instanceof RippleWithdrawFundsParams) { RippleWithdrawFundsParams xrpParams = (RippleWithdrawFundsParams) params; return withdraw( xrpParams.getCurrency(), xrpParams.getAmount(), xrpParams.getAddress(), xrpParams.getTag()); } else if (params instanceof MoneroWithdrawFundsParams) { MoneroWithdrawFundsParams xmrParams = (MoneroWithdrawFundsParams) params; return withdraw( xmrParams.getCurrency(), xmrParams.getAmount(), xmrParams.getAddress(), xmrParams.getPaymentId()); } else if (params instanceof DefaultWithdrawFundsParams) { DefaultWithdrawFundsParams defaultParams = (DefaultWithdrawFundsParams) params; return withdrawFunds( defaultParams.getCurrency(), defaultParams.getAmount(), defaultParams.getAddress()); } throw new IllegalStateException("Don't know how to withdraw: " + params); }
@Override public String withdrawFunds(WithdrawFundsParams params) throws IOException { try { if (params instanceof RippleWithdrawFundsParams) { RippleWithdrawFundsParams xrpParams = (RippleWithdrawFundsParams) params; return withdrawFunds( xrpParams.getCurrency(), xrpParams.getAmount(), xrpParams.getAddress(), xrpParams.getTag()); } else if (params instanceof MoneroWithdrawFundsParams) { MoneroWithdrawFundsParams xmrParams = (MoneroWithdrawFundsParams) params; return withdrawFunds( xmrParams.getCurrency(), xmrParams.getAmount(), xmrParams.getAddress(), xmrParams.getPaymentId()); } else if (params instanceof DefaultWithdrawFundsParams) { DefaultWithdrawFundsParams defaultParams = (DefaultWithdrawFundsParams) params; return withdrawFunds( defaultParams.getCurrency(), defaultParams.getAmount(), defaultParams.getAddress()); } throw new IllegalStateException("Don't know how to withdraw: " + params); } catch (BitfinexException e) { throw BitfinexErrorAdapter.adapt(e); } }
@Override public String withdrawFunds(WithdrawFundsParams params) throws IOException { try { if (params instanceof RippleWithdrawFundsParams) { RippleWithdrawFundsParams defaultParams = (RippleWithdrawFundsParams) params; return withdraw( defaultParams.getCurrency().getCurrencyCode(), defaultParams.getAmount(), defaultParams.getAddress(), defaultParams.getTag()); } else if (params instanceof MoneroWithdrawFundsParams) { MoneroWithdrawFundsParams moneroWithdrawFundsParams = (MoneroWithdrawFundsParams) params; return withdraw( moneroWithdrawFundsParams.getCurrency().getCurrencyCode(), moneroWithdrawFundsParams.getAmount(), moneroWithdrawFundsParams.getAddress(), moneroWithdrawFundsParams.getPaymentId()); } else if (params instanceof DefaultWithdrawFundsParams) { DefaultWithdrawFundsParams defaultParams = (DefaultWithdrawFundsParams) params; return withdrawFunds( defaultParams.getCurrency(), defaultParams.getAmount(), defaultParams.getAddress()); } throw new IllegalStateException("Don't know how to withdraw: " + params); } catch (BittrexException e) { throw BittrexErrorAdapter.adapt(e); } }
@Override public String toString() { return "MoneroWithdrawFundsParams{" + "address='" + getAddress() + '\'' + ", paymentId='" + getPaymentId() + '\'' + ", currency=" + getCurrency() + ", amount=" + getAmount() + ", commission=" + getCommission() + '}'; }
@Override public String withdrawFunds(WithdrawFundsParams params) throws IOException { if (params instanceof MoneroWithdrawFundsParams) { MoneroWithdrawFundsParams moneroWithdrawFundsParams = (MoneroWithdrawFundsParams) params; return withdrawFundsRaw( moneroWithdrawFundsParams.getCurrency(), moneroWithdrawFundsParams.getAmount(), moneroWithdrawFundsParams.getAddress(), moneroWithdrawFundsParams.getPaymentId()); } else if (params instanceof RippleWithdrawFundsParams) { RippleWithdrawFundsParams rippleWithdrawFundsParams = (RippleWithdrawFundsParams) params; return withdrawFundsRaw( rippleWithdrawFundsParams.getCurrency(), rippleWithdrawFundsParams.getAmount(), rippleWithdrawFundsParams.getAddress(), rippleWithdrawFundsParams.getTag()); } else if (params instanceof DefaultWithdrawFundsParams) { DefaultWithdrawFundsParams defaultParams = (DefaultWithdrawFundsParams) params; return withdrawFundsRaw( defaultParams.getCurrency(), defaultParams.getAmount(), defaultParams.getAddress(), null); } throw new IllegalStateException("Don't know how to withdraw: " + params); }
@Override public String withdrawFunds(WithdrawFundsParams params) throws IOException { try { if (params instanceof RippleWithdrawFundsParams) { RippleWithdrawFundsParams xrpParams = (RippleWithdrawFundsParams) params; return withdrawFunds( xrpParams.getCurrency(), xrpParams.getAmount(), xrpParams.getAddress(), xrpParams.getTag()); } else if (params instanceof MoneroWithdrawFundsParams) { MoneroWithdrawFundsParams xmrParams = (MoneroWithdrawFundsParams) params; return withdrawFunds( xmrParams.getCurrency(), xmrParams.getAmount(), xmrParams.getAddress(), xmrParams.getPaymentId()); } else if (params instanceof DefaultWithdrawFundsParams) { DefaultWithdrawFundsParams defaultParams = (DefaultWithdrawFundsParams) params; return withdrawFunds( defaultParams.getCurrency(), defaultParams.getAmount(), defaultParams.getAddress()); } throw new IllegalStateException("Don't know how to withdraw: " + params); } catch (BitfinexException e) { throw BitfinexErrorAdapter.adapt(e); } }
@Override public String withdrawFunds(WithdrawFundsParams params) throws IOException { try { if (params instanceof RippleWithdrawFundsParams) { RippleWithdrawFundsParams defaultParams = (RippleWithdrawFundsParams) params; return withdraw( defaultParams.getCurrency().getCurrencyCode(), defaultParams.getAmount(), defaultParams.getAddress(), defaultParams.getTag()); } else if (params instanceof MoneroWithdrawFundsParams) { MoneroWithdrawFundsParams moneroWithdrawFundsParams = (MoneroWithdrawFundsParams) params; return withdraw( moneroWithdrawFundsParams.getCurrency().getCurrencyCode(), moneroWithdrawFundsParams.getAmount(), moneroWithdrawFundsParams.getAddress(), moneroWithdrawFundsParams.getPaymentId()); } else if (params instanceof DefaultWithdrawFundsParams) { DefaultWithdrawFundsParams defaultParams = (DefaultWithdrawFundsParams) params; return withdrawFunds( defaultParams.getCurrency(), defaultParams.getAmount(), defaultParams.getAddress()); } throw new IllegalStateException("Don't know how to withdraw: " + params); } catch (BittrexException e) { throw BittrexErrorAdapter.adapt(e); } }