public class Server extends Object
| Modifier and Type | Class and Description |
|---|---|
class |
Server.ListenerThread
Http worker thread.
|
| Constructor and Description |
|---|
Server(int port,
RequestHandler handler,
Duration waitTime,
RedshiftLogger log)
Ad-hoc http server.
|
| Modifier and Type | Method and Description |
|---|---|
int |
getLocalPort() |
void |
listen()
Actual start server to work.
|
void |
stop()
Stops the server.
|
void |
waitForResult()
Wait for http callback result.
|
public Server(int port,
RequestHandler handler,
Duration waitTime,
RedshiftLogger log)
port - to listenhandler - functional callback. put all necessary functionality herewaitTime - how long does server wait for interaction.log - Redshift loggerpublic int getLocalPort()
public void listen()
throws IOException
IOException - all exceptions wrapped in IOExceptionpublic void waitForResult()
public void stop()
Copyright © 2024 Amazon.com Inc.. All rights reserved.