Skip to content

Commit 0d65a5e

Browse files
committed
setTimeout()
1 parent 339dfaf commit 0d65a5e

File tree

2 files changed

+10
-0
lines changed

2 files changed

+10
-0
lines changed

README.md

+6
Original file line numberDiff line numberDiff line change
@@ -118,6 +118,12 @@ will otherwise return false.
118118
119119
This method returns the realname (also called gecos) of the connection.
120120
121+
### setTimeout(timeout, [callback]) ###
122+
123+
As per the implementation socket. See
124+
[Node documentation](http://nodejs.org/api/net.html#net_socket_settimeout_timeout_callback)
125+
for details.
126+
121127
## Events ##
122128
123129
The basic-irc-socket is an event emitter. It emits five events.

irc-socket.js

+4
Original file line numberDiff line numberDiff line change
@@ -183,6 +183,10 @@ Socket.prototype = create(events.EventEmitter.prototype, {
183183
this.impl.write(message + '\r\n', 'utf-8');
184184
},
185185

186+
setTimeout: function (timeout, callback) {
187+
this.impl.setTimeout(timeout, callback);
188+
},
189+
186190
isConnected : function () {
187191
return this.connected;
188192
},

0 commit comments

Comments
 (0)