1POE::Component::IRC::CoUoskebrooCko:n:tDrPiiOsbEcu:ot:neCndoemcPpteoirnnlegn(Dt3o:)c:uImReCn:t:aCtoiooknbook::Disconnecting(3)
2
3
4
6 POE::Component::IRC::Cookbook::Disconnecting - How to disconnect
7 gracefully with PoCo-IRC
8
10 Shutting down an IRC bot can be quick and messy, or slow and graceful.
11
13 There are two ways you can shut down an IRC bot/client. The quick and
14 dirty way is rather simple:
15
16 exit;
17
18 It exits the program, shutting down the socket, and everybody online
19 sees yet another "Connection reset by peer" or "Remote end closed the
20 socket" or something.
21
22 As of version 6.50, all you need to do in order to shut down gracefully
23 is to send a "shutdown" event to the IRC component. It will make sure
24 your quit message (if any) gets delivered, and will forcibly disconnect
25 if there are any problems (faulty server or network issues). After
26 doing this, it will unregister all sessions and clean up after itself.
27
28 If you want to do something more elaborate on your own, take a look at
29 the following documentation: logged in, "connected", "quit",
30 "disconnect", and "unregister".
31
33 Rocco Caputo and Hinrik Örn Sigurðsson.
34
35
36
37perl v5.30.1 POE2:0:2C0o-m0p1o-n3e0nt::IRC::Cookbook::Disconnecting(3)