public final class AccountInfo extends Object
DTO representing account information
Account information is associated with the current balances in various currencies held on the exchange.
Constructor and Description |
---|
AccountInfo(String username,
BigDecimal tradingFee,
Iterable<Wallet> wallets)
Constructs an
AccountInfo . |
AccountInfo(String username,
BigDecimal tradingFee,
List<Wallet> wallets)
Deprecated.
Use
AccountInfo(String, BigDecimal, Map) instead, this constructor will be deleted in XChange 4.0.0. |
AccountInfo(String username,
BigDecimal tradingFee,
Map<String,Wallet> wallets)
Constructs an
AccountInfo . |
AccountInfo(String username,
Iterable<Wallet> wallets) |
AccountInfo(String username,
List<Wallet> wallets)
Deprecated.
Use
AccountInfo(String, Map) instead, this constructor will be deleted in XChange 4.0.0. |
AccountInfo(String username,
Map<String,Wallet> wallets) |
Modifier and Type | Method and Description |
---|---|
BigDecimal |
getBalance(String currency)
Deprecated.
Use
getWallet(String) instead. |
BigDecimal |
getTradingFee()
Returns the current trading fee
|
String |
getUsername() |
Wallet |
getWallet(String currency)
Returns the wallet of the specified currency.
|
List<Wallet> |
getWallets() |
String |
toString() |
@Deprecated public AccountInfo(String username, List<Wallet> wallets)
AccountInfo(String, Map)
instead, this constructor will be deleted in XChange 4.0.0.username
- The user namewallets
- The available walletspublic AccountInfo(String username, Map<String,Wallet> wallets)
AccountInfo(String, BigDecimal, Map).
@Deprecated public AccountInfo(String username, BigDecimal tradingFee, List<Wallet> wallets)
AccountInfo(String, BigDecimal, Map)
instead, this constructor will be deleted in XChange 4.0.0.username
- The user nametradingFee
- the trading feewallets
- The available walletspublic AccountInfo(String username, BigDecimal tradingFee, Iterable<Wallet> wallets)
AccountInfo
.username
- the user name.tradingFee
- the trading fee.wallets
- the wallets, the currencies of the wallets should not be duplicated.public AccountInfo(String username, BigDecimal tradingFee, Map<String,Wallet> wallets)
AccountInfo
.username
- the user name.tradingFee
- the trading fee.wallets
- the wallets, key is Currencies
.public String getUsername()
public BigDecimal getTradingFee()
public Wallet getWallet(String currency)
currency
- one of the Currencies
.@Deprecated public BigDecimal getBalance(String currency)
getWallet(String)
instead.currency
- A valid currency unit (e.g. CurrencyUnit.USD or CurrencyUnit.of("BTC"))Copyright © 2012–2016 Xeiam, LLC. All rights reserved.