public interface ShellServer
term servers: the registerTermServer(TermServer)
method registers a term server. Term servers life cycle are managed by this server.
When a term server receives an incoming connection, a JobController instance is created and
associated with this connection.
The createShell() method can be used to create JobController instance for testing purposes.| Modifier and Type | Method and Description |
|---|---|
default Future<Void> |
close()
Close the shell server, this is an asynchronous close.
|
void |
close(Handler<AsyncResult<Void>> completionHandler)
Close the shell server, this is an asynchronous close.
|
static ShellServer |
create(Vertx vertx)
Create a new shell server with specific options.
|
static ShellServer |
create(Vertx vertx,
ShellServerOptions options)
Create a new shell server with default options.
|
Shell |
createShell()
Create a new shell, the returned shell should be closed explicitely.
|
Shell |
createShell(Term term)
Create a new shell, the returned shell should be closed explicitely.
|
default Future<Void> |
listen()
Start the shell service, this is an asynchronous start.
|
ShellServer |
listen(Handler<AsyncResult<Void>> listenHandler)
Start the shell service, this is an asynchronous start.
|
ShellServer |
registerCommandResolver(CommandResolver resolver)
Register a command resolver for this server.
|
ShellServer |
registerTermServer(TermServer termServer)
Register a term server to this shell server, the term server lifecycle methods are managed by this shell server.
|
void |
shellHandler(Handler<Shell> shellHandler)
Called when a new shell is created.
|
static ShellServer create(Vertx vertx, ShellServerOptions options)
vertx - the vertxoptions - the optionsstatic ShellServer create(Vertx vertx)
vertx - the vertxShellServer registerCommandResolver(CommandResolver resolver)
resolver - the resolverShellServer registerTermServer(TermServer termServer)
termServer - the term server to addShell createShell(Term term)
term - the shell associated terminalShell createShell()
ShellServer listen(Handler<AsyncResult<Void>> listenHandler)
listenHandler - handler for getting notified when service is startedvoid close(Handler<AsyncResult<Void>> completionHandler)
completionHandler - handler for getting notified when service is stoppedCopyright © 2022 Eclipse. All rights reserved.