private void echoCRLF() throws IOException { driver.writeCRLF(); needFlush = true; }
private void writeNoFlush(char c) throws IOException { if (previousCR && c == '\n') { previousCR = false; } else if (c == '\r' || c == '\n') { previousCR = c == '\r'; io.writeCRLF(); } else { io.write(c); } } }
console.driver.write(msg); console.driver.writeCRLF(); console.driver.flush();
@Override String execute(Editor editor, EditorBuffer buffer, int[] sequence, boolean flush) throws IOException { editor.lineParser.reset(); buffer.reset(); editor.console.driver.writeCRLF(); String prompt = editor.console.shell.getPrompt(); if (prompt != null) { editor.console.driver.write(prompt); } if (flush) { editor.console.driver.flush(); } return null; } };
private void echoCRLF() throws IOException { driver.writeCRLF(); needFlush = true; }
private void echoCRLF() throws IOException { driver.writeCRLF(); needFlush = true; }
@Override String execute(Editor editor, EditorBuffer buffer, int[] sequence, boolean flush) throws IOException { editor.historyCursor = -1; editor.historyBuffer = null; String line = buffer.getLine(); editor.lineParser.append(line); if (editor.console.getMode() == Mode.VI_MOVE) { editor.console.setMode(Mode.VI_INSERT); } if (editor.lineParser.crlf()) { editor.console.driver.writeCRLF(); editor.console.driver.flush(); String request = editor.visitor.getRaw(); if (request.length() > 0) { editor.addToHistory(request); } return request; } else { buffer.append('\n'); editor.console.driver.write("> "); if (flush) { buffer.flush(); } return null; } } };
private void writeNoFlush(char c) throws IOException { if (previousCR && c == '\n') { previousCR = false; } else if (c == '\r' || c == '\n') { previousCR = c == '\r'; io.writeCRLF(); } else { io.write(c); } } }
private void writeNoFlush(char c) throws IOException { if (previousCR && c == '\n') { previousCR = false; } else if (c == '\r' || c == '\n') { previousCR = c == '\r'; io.writeCRLF(); } else { io.write(c); } } }
console.driver.write(msg); console.driver.writeCRLF(); console.driver.flush();
console.driver.write(msg); console.driver.writeCRLF(); console.driver.flush();
@Override String execute(Editor editor, EditorBuffer buffer, int[] sequence, boolean flush) throws IOException { editor.lineParser.reset(); buffer.reset(); editor.console.driver.writeCRLF(); String prompt = editor.console.shell.getPrompt(); if (prompt != null) { editor.console.driver.write(prompt); } if (flush) { editor.console.driver.flush(); } return null; } };
@Override String execute(Editor editor, EditorBuffer buffer, int[] sequence, boolean flush) throws IOException { editor.lineParser.reset(); buffer.reset(); editor.console.driver.writeCRLF(); String prompt = editor.console.shell.getPrompt(); if (prompt != null) { editor.console.driver.write(prompt); } if (flush) { editor.console.driver.flush(); } return null; } };
@Override String execute(Editor editor, EditorBuffer buffer, int[] sequence, boolean flush) throws IOException { editor.historyCursor = -1; editor.historyBuffer = null; String line = buffer.getLine(); editor.lineParser.append(line); if (editor.console.getMode() == Mode.VI_MOVE) { editor.console.setMode(Mode.VI_INSERT); } if (editor.lineParser.crlf()) { editor.console.driver.writeCRLF(); editor.console.driver.flush(); String request = editor.visitor.getRaw(); if (request.length() > 0) { editor.addToHistory(request); } return request; } else { buffer.append('\n'); editor.console.driver.write("> "); if (flush) { buffer.flush(); } return null; } } };
@Override String execute(Editor editor, EditorBuffer buffer, int[] sequence, boolean flush) throws IOException { editor.historyCursor = -1; editor.historyBuffer = null; String line = buffer.getLine(); editor.lineParser.append(line); if (editor.console.getMode() == Mode.VI_MOVE) { editor.console.setMode(Mode.VI_INSERT); } if (editor.lineParser.crlf()) { editor.console.driver.writeCRLF(); editor.console.driver.flush(); String request = editor.visitor.getRaw(); if (request.length() > 0) { editor.addToHistory(request); } return request; } else { buffer.append('\n'); editor.console.driver.write("> "); if (flush) { buffer.flush(); } return null; } } };