26 lines
480 B
Java
26 lines
480 B
Java
package terminal;
|
|
|
|
import static terminal.ControlSequenceHandler.Command.SGR;
|
|
|
|
class ControlSequenceHandler {
|
|
|
|
public static final boolean isEscape(char c) {
|
|
return c == '\u001B';
|
|
}
|
|
|
|
private boolean inControlSequence;
|
|
private int code;
|
|
private Command command;
|
|
|
|
public ControlSequenceHandler() {
|
|
this.inControlSequence = false;
|
|
this.code = 0;
|
|
this.command = SGR;
|
|
}
|
|
|
|
public static enum Command {
|
|
SGR
|
|
}
|
|
|
|
}
|