Withdrawal support

@param currency
@param amount
@param address
@return
@throws IOException
437426
@Override
  public String withdrawFunds(Currency currency, BigDecimal amount, String address)
      throws IOException {
    try {
      // determine withdrawal type
      String type = BitfinexUtils.convertToBitfinexWithdrawalType(currency.toString());
      // Bitfinex withdeawal can be from different type of wallets    *
      // we have to use one of these for now: Exchange -
      // to be able to withdraw instantly after trading for example
      // The wallet to withdraw from, can be “trading”, “exchange”, or “deposit”.
      String walletSelected = "exchange";
      // We have to convert XChange currencies to Bitfinex currencies: can be “bitcoin”, “litecoin”
      // or
      // “ether” or “tether” or “wire”.
      return withdraw(type, walletSelected, amount, address);
    } catch (BitfinexException e) {
      throw BitfinexErrorAdapter.adapt(e);
    }
  }
64479
public static CurrencyFunction currency(String fieldName) {

		Assert.hasText(fieldName, "FieldName must not be empty!");
		return currency(fieldName, null);
	}
710624
public static BitfinexFundingSymbol funding(final String bitfinexCurrency) {
		
        final String currencyNonNull = Objects.requireNonNull(bitfinexCurrency).toUpperCase();
        final BitfinexFundingCurrency currency = new BitfinexFundingCurrency(currencyNonNull);
        
		return funding(currency);
	}
1345922
public static Protos.Output createPayToAddressOutput(@Nullable Coin amount, Address address) {
        Protos.Output.Builder output = Protos.Output.newBuilder();
        if (amount != null) {
            final NetworkParameters params = address.getParameters();
            if (params.hasMaxMoney() && amount.compareTo(params.getMaxMoney()) > 0)
                throw new IllegalArgumentException("Amount too big: " + amount);
            output.setAmount(amount.value);
        } else {
            output.setAmount(0);
        }
        output.setScript(ByteString.copyFrom(ScriptBuilder.createOutputScript(address).getProgram()));
        return output.build();
    }
771743
public OvhWithdrawalDetail withdrawal_withdrawalId_details_withdrawalDetailId_GET(String withdrawalId, String withdrawalDetailId) throws IOException {
		String qPath = "/me/withdrawal/{withdrawalId}/details/{withdrawalDetailId}";
		StringBuilder sb = path(qPath, withdrawalId, withdrawalDetailId);
		String resp = exec(qPath, "GET", sb.toString(), null);
		return convertTo(resp, OvhWithdrawalDetail.class);
	}
13106
public static function getGatewayAmountOfCurrency($amount, $currencyCode) {
        $currencyCode = strtoupper($currencyCode);

        if ( ! is_numeric($amount) ) {
            throw new InvalidArgumentException('The amount value is not numeric. The [' . $amount . '] value has been given.');
        }

        $amount = (float) $amount;

        if ($amount < 0) {
            throw new InvalidArgumentException('The amount value must be positive. The [' . $amount . '] value has been given.');
        }

        if( in_array($currencyCode, self::FULL_VALUE_CURRENCIES, true) ) {
            return (int) $amount;
        }

        if( in_array($currencyCode, self::DIV_1000_VALUE_CURRENCIES, true) ) {
            return (int) ($amount * self::DIV_1000);
        }

        return (int) ($amount * self::DIV_100);
    }
176775
public OkCoinTradeResult trade(String symbol, String type, String price, String amount)
      throws IOException {
    OkCoinTradeResult tradeResult =
        okCoin.trade(apikey, symbol, type, price, amount, signatureCreator());
    return returnOrThrow(tradeResult);
  }
843166
public CoinsuperResponse<List<CoinsuperTicker>> getCoinsuperTicker(CurrencyPair currencyPair)
      throws IOException {

    Map<String, String> data = new HashMap<String, String>();
    data.put("symbol", currencyPair.toString());

    RestRequestParam parameters =
        RestApiRequestHandler.generateRequestParam(data, this.apiKey, this.secretKey);

    return coinsuper.getTickers(parameters);
  }
919115
function DoReturnTran($hostlogkey,
                          $amount,
                          $currency) {

        $posnetRequest = new PosnetRequest();

        $posnetRequest->hostlogkey = $hostlogkey;
        $posnetRequest->amount = $amount;
        $posnetRequest->currency = $currency;

        return $this->DoTran($posnetRequest, "return");
    }
1088527
public OvhPayment withdrawal_withdrawalId_payment_GET(String withdrawalId) throws IOException {
		String qPath = "/me/withdrawal/{withdrawalId}/payment";
		StringBuilder sb = path(qPath, withdrawalId);
		String resp = exec(qPath, "GET", sb.toString(), null);
		return convertTo(resp, OvhPayment.class);
	}
466213
def convert_money(amount, currency_from, currency_to):
    
    new_amount = base_convert_money(amount, currency_from, currency_to)
    return moneyed.Money(new_amount, currency_to)
323262
public void setCurrency(String currency) {
		currency = StringUtils.upperCase(currency);
		if (!CurrencyUtils.getInstance().isValidCurrency(currency)) {
			currency = "EUR";
		}
		this.currency = currency;
	}
1251751
public static String convertToBitcoinURI(Address address, Coin amount,
                                             String label, String message) {
        return convertToBitcoinURI(address.getParameters(), address.toString(), amount, label, message);
    }
784919
@Override
  public String requestDepositAddress(Currency currency, String... arguments) throws IOException {
    if (currency.equals(Currency.BTC)) {
      return getBitstampBitcoinDepositAddress().getDepositAddress();
    } else if (currency.equals(Currency.LTC)) {
      return getBitstampLitecoinDepositAddress().getDepositAddress();
    } else if (currency.equals(Currency.XRP)) {
      return getRippleDepositAddress().getAddressAndDt();
    } else if (currency.equals(Currency.BCH)) {
      return getBitstampBitcoinCashDepositAddress().getDepositAddress();
    } else if (currency.equals(Currency.ETH)) {
      return getBitstampEthereumDepositAddress().getDepositAddress();
    } else {
      throw new IllegalStateException("Unsupported currency " + currency);
    }
  }
829428
public static String convertToGeminiCcyName(String currency) {

    if (currency.toUpperCase().equals("BTC")) return "btc";
    if (currency.toUpperCase().equals("ETH")) return "eth";

    throw new GeminiException("Cannot determine withdrawal type.");
  }
329376
def litecoin_withdrawal(self, amount, address):
        
        data = {'amount': amount, 'address': address}
        return self._post("ltc_withdrawal/", data=data, return_json=True,
                          version=2)
610933
public String abucoinsPaymentMethodForCurrency(String currency) throws IOException {
    String method = null;
    AbucoinsPaymentMethod[] paymentMethods = getPaymentMethods();
    for (AbucoinsPaymentMethod apm : paymentMethods) {
      if (apm.getCurrency().equals(currency)) {
        method = apm.getType();
        break;
      }
    }

    if (method == null)
      logger.warn(
          "Unable to determine the payment method suitable for "
              + currency
              + " this will likely lead to an error");

    return method;
  }