use of org.apache.hadoop.hbase.hbtop.screen.top.TopScreenView in project hbase by apache.
the class TestFieldScreenPresenter method setup.
@Before
public void setup() {
Field sortField = Mode.REGION.getDefaultSortField();
fields = Mode.REGION.getFieldInfos().stream().map(FieldInfo::getField).collect(Collectors.toList());
fieldDisplayMap = Mode.REGION.getFieldInfos().stream().collect(() -> new EnumMap<>(Field.class), (r, fi) -> r.put(fi.getField(), fi.isDisplayByDefault()), (r1, r2) -> {
});
fieldScreenPresenter = new FieldScreenPresenter(fieldScreenView, sortField, fields, fieldDisplayMap, resultListener, topScreenView);
for (int i = 0; i < fields.size(); i++) {
Field field = fields.get(i);
if (field == sortField) {
sortFieldPosition = i;
break;
}
}
}
Aggregations