class Editor extends Plugin
EditorBuffer
Modifier and Type | Field and Description |
---|---|
(package private) EditorBuffer |
buffer
.
|
(package private) Console |
console
.
|
(package private) LinkedList<String> |
history
.
|
(package private) String |
historyBuffer
.
|
(package private) int |
historyCursor
.
|
(package private) StringBuilder |
killBuffer
The buffer that holds what we kill.
|
(package private) LineParser |
lineParser
The line parser : updated on enter key.
|
private Mode |
mode
.
|
private ArrayList<Runnable> |
modeListeners
.
|
private static ConsoleDriver |
NULL |
(package private) MultiLineVisitor |
visitor
.
|
Constructor and Description |
---|
Editor(Console console) |
Editor(Console console,
boolean echo) |
Modifier and Type | Method and Description |
---|---|
(package private) void |
addModeListener(Runnable runnable) |
(package private) void |
addToHistory(String line) |
(package private) String |
append(EditorAction action,
int[] sequence) |
(package private) String |
getCurrentLine() |
(package private) int |
getCurrentPosition() |
(package private) int |
getCursorBound()
Returns the right cursor bound depending on the current mode.
|
(package private) String |
getKillBuffer() |
(package private) Mode |
getMode() |
(package private) boolean |
isEmpty() |
(package private) void |
reset() |
(package private) void |
setKillBuffer(CharSequence s) |
(package private) void |
setMode(Mode mode) |
final EditorBuffer buffer
final MultiLineVisitor visitor
final LineParser lineParser
final LinkedList<String> history
int historyCursor
String historyBuffer
final StringBuilder killBuffer
private final ArrayList<Runnable> modeListeners
private static final ConsoleDriver NULL
void addModeListener(Runnable runnable)
void addToHistory(String line)
int getCursorBound()
String getKillBuffer()
void setKillBuffer(CharSequence s)
boolean isEmpty()
String getCurrentLine()
int getCurrentPosition()
String append(EditorAction action, int[] sequence)
void reset()
Copyright © 2015 eXo Platform SAS. All Rights Reserved.