@InterfaceAudience.Private public class TopScreenView extends AbstractScreenView
Modifier and Type | Field and Description |
---|---|
private static int |
MESSAGE_ROW |
private Integer |
pageSize |
private static int |
RECORD_HEADER_ROW |
private static int |
RECORD_START_ROW |
private static int |
SUMMARY_ROW_NUM |
private static int |
SUMMARY_START_ROW |
private TopScreenPresenter |
topScreenPresenter |
Constructor and Description |
---|
TopScreenView(Screen screen,
Terminal terminal,
long initialRefreshDelay,
Admin admin,
Mode initialMode,
List<Field> initialFields,
Field initialSortField,
Boolean initialAscendingSort,
List<RecordFilter> initialFilters,
long numberOfIterations) |
Modifier and Type | Method and Description |
---|---|
private void |
clearMessage() |
TerminalSize |
doResizeIfNecessary() |
Integer |
getPageSize() |
TerminalSize |
getTerminalSize() |
ScreenView |
handleKeyPress(KeyPress keyPress) |
ScreenView |
handleTimer() |
void |
init() |
private String |
limitLineLength(String line,
int length) |
private void |
showHeaders(List<Header> headers) |
private void |
showRecords(List<Header> headers,
List<Record> records,
Record selectedRecord) |
private void |
showSummary(Summary summary) |
void |
showTopScreen(Summary summary,
List<Header> headers,
List<Record> records,
Record selectedRecord) |
private ScreenView |
unknownCommandMessage() |
private void |
updatePageSize(TerminalSize terminalSize) |
cancelTimer, clearTerminal, getScreen, getTerminal, getTerminalPrinter, hideCursor, refreshTerminal, setCursorPosition, setTimer
private static final int SUMMARY_START_ROW
private static final int SUMMARY_ROW_NUM
private static final int MESSAGE_ROW
private static final int RECORD_HEADER_ROW
private static final int RECORD_START_ROW
private final TopScreenPresenter topScreenPresenter
public TopScreenView(Screen screen, Terminal terminal, long initialRefreshDelay, Admin admin, Mode initialMode, @Nullable List<Field> initialFields, @Nullable Field initialSortField, @Nullable Boolean initialAscendingSort, @Nullable List<RecordFilter> initialFilters, long numberOfIterations)
public void init()
init
in interface ScreenView
init
in class AbstractScreenView
@Nullable public ScreenView handleTimer()
handleTimer
in interface ScreenView
handleTimer
in class AbstractScreenView
@Nullable public ScreenView handleKeyPress(KeyPress keyPress)
handleKeyPress
in interface ScreenView
handleKeyPress
in class AbstractScreenView
@Nullable public TerminalSize getTerminalSize()
getTerminalSize
in class AbstractScreenView
@Nullable public TerminalSize doResizeIfNecessary()
doResizeIfNecessary
in class AbstractScreenView
private void updatePageSize(TerminalSize terminalSize)
@Nullable public Integer getPageSize()
public void showTopScreen(Summary summary, List<Header> headers, List<Record> records, Record selectedRecord)
private void showSummary(Summary summary)
private void showRecords(List<Header> headers, List<Record> records, Record selectedRecord)
private void showHeaders(List<Header> headers)
private String limitLineLength(String line, int length)
private void clearMessage()
private ScreenView unknownCommandMessage()
Copyright © 2007–2020 The Apache Software Foundation. All rights reserved.