# File lib/em/protocols/httpclient2.rb, line 241
241:       def self.connect *args
242:         if args.length == 2
243:           args = {:host=>args[0], :port=>args[1]}
244:         else
245:           args = args.first
246:         end
247: 
248:         h,prt,ssl = args[:host], Integer(args[:port]), (args[:tls] || args[:ssl])
249:         conn = EM.connect( h, prt, self )
250:         conn.start_tls if ssl
251:         conn.set_default_host_header( h, prt, ssl )
252:         conn
253:       end