Search in sources :

Example 6 with FiatCurrency

use of io.bitsquare.locale.FiatCurrency in project bitsquare by bitsquare.

the class OfferBookViewModelTest method getSpecificBanksAccount.

private PaymentAccount getSpecificBanksAccount(String currencyCode, String countryCode, String bankId, ArrayList<String> bankIds) {
    SpecificBanksAccount paymentAccount = new SpecificBanksAccount();
    paymentAccount.setSingleTradeCurrency(new FiatCurrency(currencyCode));
    paymentAccount.setCountry(new Country(countryCode, null, null));
    ((SpecificBanksAccountContractData) paymentAccount.getContractData()).setBankId(bankId);
    bankIds.forEach(((SpecificBanksAccountContractData) paymentAccount.getContractData())::addAcceptedBank);
    return paymentAccount;
}
Also used : Country(io.bitsquare.locale.Country) FiatCurrency(io.bitsquare.locale.FiatCurrency)

Example 7 with FiatCurrency

use of io.bitsquare.locale.FiatCurrency in project bitsquare by bitsquare.

the class OfferBookViewModelTest method getSameBankAccount.

private PaymentAccount getSameBankAccount(String currencyCode, String countryCode, String bankId) {
    SameBankAccount paymentAccount = new SameBankAccount();
    paymentAccount.setSingleTradeCurrency(new FiatCurrency(currencyCode));
    paymentAccount.setCountry(new Country(countryCode, null, null));
    ((SameBankAccountContractData) paymentAccount.getContractData()).setBankId(bankId);
    return paymentAccount;
}
Also used : Country(io.bitsquare.locale.Country) FiatCurrency(io.bitsquare.locale.FiatCurrency)

Example 8 with FiatCurrency

use of io.bitsquare.locale.FiatCurrency in project bitsquare by bitsquare.

the class OfferBookViewModelTest method getSepaAccount.

private PaymentAccount getSepaAccount(String currencyCode, String countryCode, String bic, ArrayList<String> countryCodes) {
    CountryBasedPaymentAccount paymentAccount = new SepaAccount();
    paymentAccount.setSingleTradeCurrency(new FiatCurrency(currencyCode));
    paymentAccount.setCountry(new Country(countryCode, null, null));
    ((SepaAccountContractData) paymentAccount.getContractData()).setBic(bic);
    countryCodes.forEach(((SepaAccountContractData) paymentAccount.getContractData())::addAcceptedCountry);
    return paymentAccount;
}
Also used : Country(io.bitsquare.locale.Country) FiatCurrency(io.bitsquare.locale.FiatCurrency)

Aggregations

FiatCurrency (io.bitsquare.locale.FiatCurrency)8 Country (io.bitsquare.locale.Country)4 TradeCurrency (io.bitsquare.locale.TradeCurrency)3 Inject (com.google.inject.Inject)2 ActivatableDataModel (io.bitsquare.gui.common.model.ActivatableDataModel)2 GUIUtil (io.bitsquare.gui.util.GUIUtil)2 CryptoCurrency (io.bitsquare.locale.CryptoCurrency)2 CryptoCurrencyAccount (io.bitsquare.payment.CryptoCurrencyAccount)2 PaymentAccount (io.bitsquare.payment.PaymentAccount)2 PaymentMethod (io.bitsquare.payment.PaymentMethod)2 TradeManager (io.bitsquare.trade.TradeManager)2 OpenOfferManager (io.bitsquare.trade.offer.OpenOfferManager)2 Preferences (io.bitsquare.user.Preferences)2 User (io.bitsquare.user.User)2 ArrayList (java.util.ArrayList)2 List (java.util.List)2 Collectors (java.util.stream.Collectors)2 FXCollections (javafx.collections.FXCollections)2 ObservableList (javafx.collections.ObservableList)2 SetChangeListener (javafx.collections.SetChangeListener)2