EventBus icon indicating copy to clipboard operation
EventBus copied to clipboard

Make the library extensible

Open kkozmic-seek opened this issue 7 years ago • 2 comments

There were a few PRs and issues reported over the years asking for added thread modes, extra context etc.

I have a need for something like that myself but instead of bloating the framework with extra features I propose to make it more extensible in some key areas to allow for application specific customisation.

Happy to PR this if there's at all interest

kkozmic-seek avatar May 03 '17 22:05 kkozmic-seek

IMHO the only thread mode that should be supported by an EventBus is async (where the async thread comes from is an orthogonal issue), with perhaps a convenience method to hand that off to the UI handler.

Anything else just breaks encapsulation and couples the caller with the endpoints.

What extra thread modes / context are you referring to?

william-ferguson-au avatar May 03 '17 22:05 william-ferguson-au

Depends what you're using the bus for. We're using it as UI event aggregator so I'm interested in features around that. Synchronous calls, async calls on UI thread, delayed calls on UI thread, buffered calls on UI thread etc.

kkozmic-seek avatar May 04 '17 00:05 kkozmic-seek