Skip to content

Make it possible to use lambdas instead of *Listener objects #246

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
michaelklishin opened this issue Feb 23, 2017 · 0 comments
Closed

Make it possible to use lambdas instead of *Listener objects #246

michaelklishin opened this issue Feb 23, 2017 · 0 comments
Assignees
Milestone

Comments

@michaelklishin
Copy link
Contributor

Now that master can require JDK 8 we can begin retrofitting the API to accept lambdas. One relatively easy step would be to make sure we accept lambdas for all the listeners which are typically SMIs (Single Method Interfaces).

For backwards compatibility we should still accept SMIs but wrap them into lambdas under the hood.

@michaelklishin michaelklishin added this to the 5.0.0 milestone Feb 23, 2017
acogoluegnes added a commit that referenced this issue Feb 27, 2017
A proposal to use lambdas in listeners objects. Some callback
interfaces have been introduced when necessary (not necessary
for e.g. ShutdownListener). Lambdas are wrapped into the original
listener interfaces. Provide a simple test to experiment with the
API.

References #246
@acogoluegnes acogoluegnes self-assigned this Feb 27, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants