ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/Coro/Event/Socket.pm
(Generate patch)

Comparing Coro/Event/Socket.pm (file contents):
Revision 1.7 by root, Mon Sep 24 01:36:21 2001 UTC vs.
Revision 1.8 by root, Wed Oct 3 01:33:46 2001 UTC

152 152
153 $fh; 153 $fh;
154} 154}
155 155
156=item connect, listen, bind, getsockopt, setsockopt, 156=item connect, listen, bind, getsockopt, setsockopt,
157send, recv, peername, sockname 157send, recv, peername, sockname, shutdown
158 158
159Do the same thing as the perl builtins or IO::Socket methods (but return 159Do the same thing as the perl builtins or IO::Socket methods (but return
160true on EINPROGRESS). Remember that these must be method calls. 160true on EINPROGRESS). Remember that these must be method calls.
161 161
162=cut 162=cut
168sub setsockopt { setsockopt tied(${$_[0]})->[0], $_[1], $_[2], $_[3] } 168sub setsockopt { setsockopt tied(${$_[0]})->[0], $_[1], $_[2], $_[3] }
169sub send { send tied(${$_[0]})->[0], $_[1], $_[2], @_ > 2 ? $_[3] : () } 169sub send { send tied(${$_[0]})->[0], $_[1], $_[2], @_ > 2 ? $_[3] : () }
170sub recv { recv tied(${$_[0]})->[0], $_[1], $_[2], @_ > 2 ? $_[3] : () } 170sub recv { recv tied(${$_[0]})->[0], $_[1], $_[2], @_ > 2 ? $_[3] : () }
171sub sockname { getsockname tied(${$_[0]})->[0] } 171sub sockname { getsockname tied(${$_[0]})->[0] }
172sub peername { getpeername tied(${$_[0]})->[0] } 172sub peername { getpeername tied(${$_[0]})->[0] }
173sub shutdown { shutdown tied(${$_[0]})->[0] }
173 174
174=item ($peername, $fh) = $listen_fh->accept 175=item ($peername, $fh) = $listen_fh->accept
175 176
176In scalar context, returns the newly accepted socket (or undef) and in 177In scalar context, returns the newly accepted socket (or undef) and in
177list context return the ($fh, $peername) pair (or nothing). 178list context return the ($fh, $peername) pair (or nothing).

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines