You can have multiple event buses and other customization there as needed, but you have sensible defaults to keep code small most of the time too.
Square also has one called Otto. If you want a lot of syntax and Java rather than Android, you might as well go full streaming with the RxJava library.
With event framework,we should use little helper function to wrap each event type,at least that's what I have seen.Windows event tracing(ETW) comes to mind,one of the complex api written[1].I always thought that every application should make use of ETW infrastrucutre. Compared to perf_events or may be lttng in linux(I am not sure how difficult to integrate to perf_events).Currently there are good and easy framework for ETW in .net [2]. But once you integrate your app,your app suddenly gains performance tuning,debugging capability easily. I think this should hold true for any event framework!!
And yeah, it requires a bit more typting if you want to enforce a certain event format and want to add more parameters. But you only do that once, and I'd say you gain much more for your effort.
Event Bus often get abused, I made this framework for Android so that the framework can scale as you have more and more features and developers working on it: https://github.com/edisonw/PennStation
[+] [-] typpytyper|9 years ago|reply
It needs a more compact API.
[+] [-] lnanek2|9 years ago|reply
There are more established event buses in Android with simpler syntax, like greenrobot's: EventBus.getInstance().post(new LogEvent("v1", "v2"));
Seen here: http://greenrobot.org/eventbus/documentation/how-to-get-star...
You can have multiple event buses and other customization there as needed, but you have sensible defaults to keep code small most of the time too.
Square also has one called Otto. If you want a lot of syntax and Java rather than Android, you might as well go full streaming with the RxJava library.
[+] [-] hitr|9 years ago|reply
[1]https://mollyrocket.com/casey/stream_0029.html [2]https://www.nuget.org/packages/Microsoft.Diagnostics.Tracing...
[+] [-] zer0gravity|9 years ago|reply
[+] [-] wzsddtc|9 years ago|reply
[+] [-] kashif|9 years ago|reply
[+] [-] oldmanjay|9 years ago|reply
[+] [-] CarolineW|9 years ago|reply
But you knew that, because it was you who submitted it.
[+] [-] paradisechris|9 years ago|reply