java - Publish-Subscribe Event Handlers - Static vs. Singleton -


i'm designing event bus, , stands, methods wishing subscribe events must static, declaring classes registered directly class objects. however, i'm aware guava includes an event bus accepts object during registration , prefers instance methods subscribers. there advantage latter system? in practice i'm not sure of difference, object registered singleton. i'd interested hear pros , cons.


Comments

Popular posts from this blog

android - Gradle sync Error:Configuration with name 'default' not found -

java - Andrioid studio start fail: Fatal error initializing 'null' -

html - jQuery UI Sortable - Remove placeholder after item is dropped -