private TxactionList filterTxactions(List<Account> accounts,
List<Txaction> txactions, CurrencyParam currency, BooleanParam uneditedOnly,
IntegerParam limit, IntegerParam offset, Set<String> tagUris,
Set<String> merchantNames, BigDecimal amount, String query) {
final TxactionListBuilder txactionListBuilder = builderProvider.get();
txactionListBuilder.setAccounts(accounts);
txactionListBuilder.setUnedited(uneditedOnly.getValue());
txactionListBuilder.setTags(getTags(tagUris));
txactionListBuilder.setCurrency(currency.getValue());
if (!merchantNames.isEmpty()) {
txactionListBuilder.setMerchantNames(merchantNames);
}
if (limit != null) {
txactionListBuilder.setLimit(limit.getValue());
}
if (offset != null) {
txactionListBuilder.setOffset(offset.getValue());
}
if (amount != null) {
txactionListBuilder.setAmount(amount);
}
if (query != null) {
txactionListBuilder.setQuery(query);
}
final TxactionList filteredTxactions = txactionListBuilder.build(txactions);
return filteredTxactions;
}