code: public static HostAndPort of(String host, int port) {
  
          LettuceAssert.isTrue(isValidPort(port), String.format("Port out of range: %s", port));
  
          HostAndPort parsedHost = parse(host);
          LettuceAssert.isTrue(!parsedHost.hasPort(), String.format("Host has a port: %s", host));
          return new HostAndPort(host, port);
      }
docs: Create a {@link HostAndPort} of {@code host} and {@code port}
  
  @param host the hostname
  @param port a valid port
  @return the {@link HostAndPort} of {@code host} and {@code port}