use of name.abuchen.portfolio.datatransfer.ImportAction in project portfolio by buchen.
the class AssertImportActions method check.
public void check(List<Extractor.Item> items, ImportAction.Context context) {
for (Extractor.Item item : items) {
for (ImportAction action : actions) {
ImportAction.Status status = item.apply(action, context);
assertThat(status.getMessage(), status.getCode(), is(ImportAction.Status.Code.OK));
}
}
}
use of name.abuchen.portfolio.datatransfer.ImportAction in project portfolio by buchen.
the class ReviewExtractedItemsPage method checkEntries.
private void checkEntries(List<ExtractedEntry> entries) {
List<ImportAction> actions = new ArrayList<>();
actions.add(new CheckValidTypesAction());
actions.add(new DetectDuplicatesAction());
actions.add(new CheckCurrenciesAction());
for (ExtractedEntry entry : entries) {
entry.clearStatus();
for (ImportAction action : actions) entry.addStatus(entry.getItem().apply(action, this));
}
}
Aggregations