This repository was archived by the owner on Apr 30, 2019. It is now read-only.
Explicit EventHandler creation avoiding reflection#121
Open
ggalmazor wants to merge 2 commits intosquare:masterfrom
ggalmazor:master
Open
Explicit EventHandler creation avoiding reflection#121ggalmazor wants to merge 2 commits intosquare:masterfrom ggalmazor:master
ggalmazor wants to merge 2 commits intosquare:masterfrom
ggalmazor:master
Conversation
New register & unregister methods in Bus for explicit (not by reflection) EventHandler definition Added a generic Callback interface to be extended (implemented) by third parties Added a specific implementation of MethodCallingCallback with the orginal implementation of an EventHandler created by reflection of @subscribe annotations in objects Added tests to cover added features Added example of explicir registration&un-registration of Callbacks in sample project
Author
|
I'm realizing that I've changed the minor version number... I can rollback that change if needed. Apologies. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The motivation behind this changes is to be able to create and register new event listeners in run-time, instead of depending on annotation reflection.
The original API for Bus instances is intact and all tests are passing.
This changes have been testes in the sample project and in a sandbox project loading Otto as a Maven dependency.
Commit message:
New register & unregister methods in Bus for explicit (not by reflection) EventHandler definition
Added a generic Callback interface to be extended (implemented) by third parties
Added a specific implementation of MethodCallingCallback with the original implementation of an EventHandler created by reflection of @subscribe annotations in objects
Added tests to cover added features
Added example of explicit registration&un-registration of Callbacks in sample project