Class ServerInfo


  • public class ServerInfo
    extends java.lang.Object
    Represents the connection information for a generic server to communicate with.
    • Constructor Summary

      Constructors 
      Constructor Description
      ServerInfo​(java.lang.String hostname, int port, boolean secure)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.String getHostname()
      Get the hostname of the server.
      int getPort()
      Get the port number of the server.
      boolean isSecure()
      Should a secure connection be used for this server?
      java.lang.String toString()  
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • ServerInfo

        public ServerInfo​(java.lang.String hostname,
                          int port,
                          boolean secure)
    • Method Detail

      • getHostname

        public java.lang.String getHostname()
        Get the hostname of the server.

        This may by a fully qualified domain name or an IP address.

        Returns:
        The server's hostname.
      • getPort

        public int getPort()
        Get the port number of the server.

        If set to zero a DNS lookup will be performed to identify the port to connect to.

        Returns:
        The server's port number.
      • isSecure

        public boolean isSecure()
        Should a secure connection be used for this server?

        The transport type enum can supersede this value.

        Returns:
        true if the connection should be secured, false otherwise.
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object