Package io.quarkus.deployment.console
Class DelegateConnection
- java.lang.Object
-
- io.quarkus.deployment.console.DelegateConnection
-
- All Implemented Interfaces:
AutoCloseable
,org.aesh.terminal.Connection
public class DelegateConnection extends Object implements org.aesh.terminal.Connection
Fake connection that can be used to stop a running aesh instance If you create a console with one of these and then close it Aesh will assume the program is done and exit
-
-
Field Summary
Fields Modifier and Type Field Description (package private) boolean
closed
-
Constructor Summary
Constructors Constructor Description DelegateConnection(org.aesh.terminal.Connection delegate)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
close()
void
close(int exit)
org.aesh.terminal.Device
device()
org.aesh.terminal.Attributes
enterRawMode()
org.aesh.terminal.Attributes
getAttributes()
Consumer<Void>
getCloseHandler()
org.aesh.terminal.tty.Point
getCursorPosition()
Consumer<org.aesh.terminal.tty.Signal>
getSignalHandler()
Consumer<org.aesh.terminal.tty.Size>
getSizeHandler()
Consumer<int[]>
getStdinHandler()
Charset
inputEncoding()
void
openBlocking()
void
openNonBlocking()
Charset
outputEncoding()
boolean
put(org.aesh.terminal.tty.Capability capability, Object... objects)
void
setAttributes(org.aesh.terminal.Attributes attributes)
void
setCloseHandler(Consumer<Void> consumer)
void
setSignalHandler(Consumer<org.aesh.terminal.tty.Signal> consumer)
void
setSizeHandler(Consumer<org.aesh.terminal.tty.Size> consumer)
void
setStdinHandler(Consumer<int[]> consumer)
org.aesh.terminal.tty.Size
size()
Consumer<int[]>
stdoutHandler()
boolean
supportsAnsi()
org.aesh.terminal.Connection
write(String s)
-
-
-
Method Detail
-
device
public org.aesh.terminal.Device device()
- Specified by:
device
in interfaceorg.aesh.terminal.Connection
-
size
public org.aesh.terminal.tty.Size size()
- Specified by:
size
in interfaceorg.aesh.terminal.Connection
-
getSizeHandler
public Consumer<org.aesh.terminal.tty.Size> getSizeHandler()
- Specified by:
getSizeHandler
in interfaceorg.aesh.terminal.Connection
-
setSizeHandler
public void setSizeHandler(Consumer<org.aesh.terminal.tty.Size> consumer)
- Specified by:
setSizeHandler
in interfaceorg.aesh.terminal.Connection
-
getSignalHandler
public Consumer<org.aesh.terminal.tty.Signal> getSignalHandler()
- Specified by:
getSignalHandler
in interfaceorg.aesh.terminal.Connection
-
setSignalHandler
public void setSignalHandler(Consumer<org.aesh.terminal.tty.Signal> consumer)
- Specified by:
setSignalHandler
in interfaceorg.aesh.terminal.Connection
-
getStdinHandler
public Consumer<int[]> getStdinHandler()
- Specified by:
getStdinHandler
in interfaceorg.aesh.terminal.Connection
-
setStdinHandler
public void setStdinHandler(Consumer<int[]> consumer)
- Specified by:
setStdinHandler
in interfaceorg.aesh.terminal.Connection
-
stdoutHandler
public Consumer<int[]> stdoutHandler()
- Specified by:
stdoutHandler
in interfaceorg.aesh.terminal.Connection
-
setCloseHandler
public void setCloseHandler(Consumer<Void> consumer)
- Specified by:
setCloseHandler
in interfaceorg.aesh.terminal.Connection
-
getCloseHandler
public Consumer<Void> getCloseHandler()
- Specified by:
getCloseHandler
in interfaceorg.aesh.terminal.Connection
-
close
public void close()
- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceorg.aesh.terminal.Connection
-
openBlocking
public void openBlocking()
- Specified by:
openBlocking
in interfaceorg.aesh.terminal.Connection
-
openNonBlocking
public void openNonBlocking()
- Specified by:
openNonBlocking
in interfaceorg.aesh.terminal.Connection
-
put
public boolean put(org.aesh.terminal.tty.Capability capability, Object... objects)
- Specified by:
put
in interfaceorg.aesh.terminal.Connection
-
getAttributes
public org.aesh.terminal.Attributes getAttributes()
- Specified by:
getAttributes
in interfaceorg.aesh.terminal.Connection
-
setAttributes
public void setAttributes(org.aesh.terminal.Attributes attributes)
- Specified by:
setAttributes
in interfaceorg.aesh.terminal.Connection
-
inputEncoding
public Charset inputEncoding()
- Specified by:
inputEncoding
in interfaceorg.aesh.terminal.Connection
-
outputEncoding
public Charset outputEncoding()
- Specified by:
outputEncoding
in interfaceorg.aesh.terminal.Connection
-
supportsAnsi
public boolean supportsAnsi()
- Specified by:
supportsAnsi
in interfaceorg.aesh.terminal.Connection
-
close
public void close(int exit)
- Specified by:
close
in interfaceorg.aesh.terminal.Connection
-
write
public org.aesh.terminal.Connection write(String s)
- Specified by:
write
in interfaceorg.aesh.terminal.Connection
-
enterRawMode
public org.aesh.terminal.Attributes enterRawMode()
- Specified by:
enterRawMode
in interfaceorg.aesh.terminal.Connection
-
getCursorPosition
public org.aesh.terminal.tty.Point getCursorPosition()
- Specified by:
getCursorPosition
in interfaceorg.aesh.terminal.Connection
-
-