GreenRobot EventBus
suggest changeSyntax
- @Subscribe(threadMode = ThreadMode.POSTING) public void onEvent(EventClass event) { }
Parameters
|Thread Mode|Description| |———––|–––––––| |ThreadMode.POSTING
|Will be called on the same thread that the event was posted on. This is the default mode.| |ThreadMode.MAIN
|Will be called on the main UI thread.| |ThreadMode.BACKGROUND
|Will be called on a background thread. If the posting thread isn’t the main thread it will be used. If posted on the main thread EventBus
has a single background thread that it will use.| |ThreadMode.ASYNC
|Will be called on its own thread. |
Found a mistake? Have a question or improvement idea?
Let me know.
Table Of Contents