aboutsummaryrefslogtreecommitdiffstats
path: root/lib/net/protocol.rb
diff options
context:
space:
mode:
authoraamine <aamine@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2000-05-18 08:57:37 +0000
committeraamine <aamine@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2000-05-18 08:57:37 +0000
commit08a0727577e23ee55ce0eb09a78826f7f7642411 (patch)
tree8b56995afa158a3faea8a5bc8cfed2f97cfbc706 /lib/net/protocol.rb
parentf63956c52c796194f5a4f5178775d80582e543c1 (diff)
downloadruby-08a0727577e23ee55ce0eb09a78826f7f7642411.tar.gz
o protocol.rb, http.rb, smtp.rb, pop.rb: update RD documents
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@701 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'lib/net/protocol.rb')
-rw-r--r--lib/net/protocol.rb18
1 files changed, 10 insertions, 8 deletions
diff --git a/lib/net/protocol.rb b/lib/net/protocol.rb
index 399b2bbdd4..c52b9d5184 100644
--- a/lib/net/protocol.rb
+++ b/lib/net/protocol.rb
@@ -30,17 +30,15 @@ Object
: new( address = 'localhost', port = nil )
This method Creates a new protocol object.
-: start( address = 'localhost', port = nil, *args )
-: start( address = 'localhost', port = nil, *args ){|proto| .... }
- This method creates a new Protocol object and start session.
- If you call this method with block, Protocol object give itself
- to block and finish session when block returns.
+: start( address = 'localhost', port = nil, *protoargs )
+: start( address = 'localhost', port = nil, *protoargs ) {|proto| .... }
+ This method creates a new Protocol object and opens a session.
+ equals to Net::Protocol.new( address, port ).start( *protoargs )
: Proxy( address, port )
This method creates a proxy class of its protocol.
Arguments are address/port of proxy host.
-
=== Methods
: address
@@ -50,11 +48,15 @@ Object
connecting port number
: start( *args )
- This method start protocol. If you call this method when the protocol
- is already started, this only returns false without doing anything.
+: start( *args ) {|proto| .... }
+ This method starts protocol. If protocol was already started,
+ do nothing and returns false.
'*args' are specified in subclasses.
+ When is called as iterator, gives Protocol object to block and
+ close session when block finished.
+
: finish
This method ends protocol. If you call this method before protocol starts,
it only return false without doing anything.