1 package au.gov.amsa.streams; 2 3 public class HostPort { 4 private final String host; 5 private final int port; 6 private final long quietTimeoutMs; 7 private final long reconnectDelayMs; 8 9 public HostPort(String host, int port, long quietTimeoutMs, 10 long reconnectDelayMs) { 11 this.host = host; 12 this.port = port; 13 this.quietTimeoutMs = quietTimeoutMs; 14 this.reconnectDelayMs = reconnectDelayMs; 15 } 16 17 public String getHost() { 18 return host; 19 } 20 21 public int getPort() { 22 return port; 23 } 24 25 public long getQuietTimeoutMs() { 26 return quietTimeoutMs; 27 } 28 29 public long getReconnectDelayMs() { 30 return reconnectDelayMs; 31 } 32 33 public static HostPort create(String host, int port, long quietTimeoutMs, 34 long reconnectDelayMs) { 35 return new HostPort(host, port,quietTimeoutMs, reconnectDelayMs); 36 } 37 38 }