Interface IServer

All Superinterfaces:
AutoCloseable, Closeable

public interface IServer extends Closeable
An interface for the Server implementation. Solely created to provide better testing access
  • Method Details

    • start

      void start()
      This is where the central loop of our server is started
    • getHost

      String getHost()
      Get the string version of the address of this server. See InetAddress.getHostAddress()
    • getPort

      int getPort()
    • removeMyRecord

      void removeMyRecord(ISocketWrapper socketWrapper)
      When we first create a SocketWrapper in Server, we provide it a reference back to this object, so that it can call this command. This class maintains a list of open sockets in setOfSWs, and allows generated SocketWrappers to deregister themselves from this list by using this method.
    • getCentralLoopFuture

      Future<?> getCentralLoopFuture()
      Obtain the Future of the central loop of this server object
    • getServerType

      HttpServerType getServerType()