use of bisq.core.payment.payload.NationalBankAccountPayload in project bisq-desktop by bisq-network.
the class OfferBookViewModelTest method getNationalBankAccount.
private PaymentAccount getNationalBankAccount(String currencyCode, String countryCode, String bankId) {
CountryBasedPaymentAccount paymentAccount = new NationalBankAccount();
paymentAccount.setSingleTradeCurrency(new FiatCurrency(currencyCode));
paymentAccount.setCountry(new Country(countryCode, null, null));
((NationalBankAccountPayload) paymentAccount.getPaymentAccountPayload()).setBankId(bankId);
return paymentAccount;
}
use of bisq.core.payment.payload.NationalBankAccountPayload in project bisq-api by mrosseel.
the class NationalBankAccountPaymentAccountConverter method toBusinessModel.
@Override
public NationalBankAccount toBusinessModel(NationalBankAccountPaymentAccount rest) {
final NationalBankAccount business = new NationalBankAccount();
business.init();
final NationalBankAccountPayload paymentAccountPayload = (NationalBankAccountPayload) business.getPaymentAccountPayload();
paymentAccountPayload.setAccountNr(rest.accountNr);
paymentAccountPayload.setAccountType(rest.accountType);
paymentAccountPayload.setBankId(rest.bankId);
paymentAccountPayload.setBankName(rest.bankName);
paymentAccountPayload.setBranchId(rest.branchId);
paymentAccountPayload.setCountryCode(rest.countryCode);
paymentAccountPayload.setHolderName(rest.holderName);
paymentAccountPayload.setHolderTaxId(rest.holderTaxId);
toBusinessModel(business, rest);
return business;
}
Aggregations