ClientObject:connect

Connect to a server.

Function

Synopsis

clientobject:connect(host, port, dns)

Arguments

string host
The host to connect to.
number port
The port to connect to on the host.
string dns
Specifies if the host is a name or an IP (If its a hostname, Then do a DNS lookup). Default is IP.

Returns

Assertion upon failure, or true upon success. self.host becomes the host name. self.port becomes the port name. self.connected becomes a boolean set to true.

See Also

Other Languages