code: public static Socket createSocket(UrlParser urlParser, String host) throws IOException {
      return socketHandler.apply(urlParser, host);
    }
docs: Create socket accordingly to options.
  
  @param urlParser urlParser
  @param host      hostName ( mandatory only for named pipe)
  @return a nex socket
  @throws IOException if connection error occur