… | |
… | |
69 | |
69 | |
70 | =over 4 |
70 | =over 4 |
71 | |
71 | |
72 | =item fh => $filehandle [MANDATORY] |
72 | =item fh => $filehandle [MANDATORY] |
73 | |
73 | |
|
|
74 | #=item fh => $filehandle [C<fh> or C<connect> MANDATORY] |
|
|
75 | |
74 | The filehandle this L<AnyEvent::Handle> object will operate on. |
76 | The filehandle this L<AnyEvent::Handle> object will operate on. |
75 | |
|
|
76 | NOTE: The filehandle will be set to non-blocking mode (using |
77 | NOTE: The filehandle will be set to non-blocking mode (using |
77 | C<AnyEvent::Util::fh_nonblocking>) by the constructor and needs to stay in |
78 | C<AnyEvent::Util::fh_nonblocking>) by the constructor and needs to stay in |
78 | that mode. |
79 | that mode. |
|
|
80 | |
|
|
81 | #=item connect => [$host, $service] |
|
|
82 | # |
|
|
83 | # You have to specify either this parameter, or C<connect>, below. |
|
|
84 | #Try to connect to the specified host and service (port), using |
|
|
85 | #C<AnyEvent::Socket::tcp_connect>. |
|
|
86 | # |
|
|
87 | #When this |
79 | |
88 | |
80 | =item on_eof => $cb->($handle) |
89 | =item on_eof => $cb->($handle) |
81 | |
90 | |
82 | Set the callback to be called when an end-of-file condition is detected, |
91 | Set the callback to be called when an end-of-file condition is detected, |
83 | i.e. in the case of a socket, when the other side has closed the |
92 | i.e. in the case of a socket, when the other side has closed the |