Class RpcServer

java.lang.Object
xal.extension.service.RpcServer

public class RpcServer extends Object
RpcServer implements a server which handles remote requests against registered handlers.
Author:
tap
  • Constructor Details

  • Method Details

    • getPort

      public int getPort()
      Get the port used by the web server.
      Returns:
      The port used by the web server.
    • getHost

      public String getHost()
      Get the host address used for the web server.
      Returns:
      The host address used for the web server.
    • start

      public void start()
      start the server, listen for remote requests and dispatch them to the appropriate handlers
    • shutdown

      public void shutdown() throws IOException
      shutdown the server
      Throws:
      IOException
    • addHandler

      public <T> void addHandler(String serviceName, Class<T> protocol, T provider)
      add a handler to associate with the specified service and provider
    • removeHandler

      public void removeHandler(String serviceName)
      remove the registered handler