Class Connection

  • All Implemented Interfaces:
    java.io.Closeable, java.lang.AutoCloseable

    public class Connection
    extends java.lang.Object
    implements java.io.Closeable
    Represents a connection to a server. This is part of the Jedis compatibility layer.
    • Constructor Detail

      • Connection

        public Connection​(HostAndPort hostAndPort)
    • Method Detail

      • getHostAndPort

        public HostAndPort getHostAndPort()
        Get the host and port for this connection
      • getHost

        public java.lang.String getHost()
        Get the host
      • getPort

        public int getPort()
        Get the port
      • close

        public void close()
        Specified by:
        close in interface java.lang.AutoCloseable
        Specified by:
        close in interface java.io.Closeable