raisedragon / pircbotx

Automatically exported from code.google.com/p/pircbotx
0 stars 0 forks source link

When sending a message itself, Pircbotx should trigger an event #161

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Background
I coded a chat logger listener that logs all chats with a customizable format 
that, by default, imitates the way mIRC logs things.
https://github.com/Bhasmithal/Extended-PircBotX/blob/master/modular-pircbot-modu
les/src/main/java/org/pircbotx/listeners/ChatLoggerListener.java

The problem however is that when PircBotX sends a message/action/... to any 
channel, no event is triggered and thus I cannot catch the message the same way 
as other messages and I can't log it easily.

I could, whenever I send a message with PircBotX, call my logger with a 
specific format but it is cumbersome as it breaks the layer separation.

Obviously, generating an event when PircBotX sends a message might end up in an 
infinite loop if a developer doesn't develop a listener well (i.e. send a 
message with PircBotX each time a message is received). However I don't think 
that should be the responsibility of PircBotX to block the developer from doing 
so.

Original issue reported on code.google.com by emmanuel...@gmail.com on 4 Jan 2014 at 12:05

GoogleCodeExporter commented 9 years ago
Around mid 2013 I worked on adding Output*Events but stopped since I thought it 
was useless. There's still branch/head Revision c27a5dd9cc46 with the last of 
the work I did.

I will pick this back up hopefully in time for next version.

Original comment by Lord.Qua...@gmail.com on 4 Jan 2014 at 10:22

GoogleCodeExporter commented 9 years ago
Merging into Issue #195 since it encompasses both Input and Output parsing

Original comment by Lord.Qua...@gmail.com on 31 Aug 2014 at 8:44