From 26b9cd878a91a5ab495762fc168b4bb7b74c4d62 Mon Sep 17 00:00:00 2001 From: shugo Date: Thu, 22 Jul 2004 23:52:11 +0000 Subject: * lib/net/imap.rb (disconnected?): new method. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@6685 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- lib/net/imap.rb | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'lib/net/imap.rb') diff --git a/lib/net/imap.rb b/lib/net/imap.rb index 7e8d574fbe..705d54b0ce 100644 --- a/lib/net/imap.rb +++ b/lib/net/imap.rb @@ -289,6 +289,11 @@ module Net @sock.close end + # Returns true if disconnected from the server. + def disconnected? + return @sock.closed? + end + # Sends a CAPABILITY command, and returns an array of # capabilities that the server supports. Each capability # is a string. See [IMAP] for a list of possible -- cgit v1.2.3