All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.knowm.xchange.bitfinex.v1.dto.account.BitfinexAccountFeesResponse Maven / Gradle / Ivy

There is a newer version: 4.3.19.2
Show newest version
package org.knowm.xchange.bitfinex.v1.dto.account;

import com.fasterxml.jackson.annotation.JsonProperty;
import java.math.BigDecimal;
import java.util.Map;
import java.util.stream.Collectors;
import org.knowm.xchange.bitfinex.v1.BitfinexAdapters;
import org.knowm.xchange.currency.Currency;

/** @author ujjwal on 23/02/18. */
public class BitfinexAccountFeesResponse {
  private final Map withdraw;

  public BitfinexAccountFeesResponse(
      @JsonProperty("withdraw") final Map withdraw) {
    this.withdraw =
        withdraw.entrySet().stream() // Sting needs to be adapted (i.e., DSH -> DASH)
            .collect(
                Collectors.toMap(
                    entry -> new Currency(BitfinexAdapters.adaptBitfinexCurrency(entry.getKey())),
                    entry -> entry.getValue()));
  }

  public Map getWithdraw() {
    return withdraw;
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy