google / google/guice

Simplify syntax for injecting into an interceptor

Open
#465 6 comments 0 reactions 0 assignees View on GitHub
imported Priority-Low
Dominant language
Java
Stars
12.7k
Forks
1.7k
Avg merge
11m
Merged PRs (30d)
2

Description

_From [eric.jain](https://code.google.com/u/102186567666012743407/) on January 29, 2010 15:07:43_

Instead of e.g.:

  Timer timer = new Timer();
  requestInjection(timer); // injects e.g. a Logger
  bindInterceptor(Matchers.any(), Matchers.annotatedWith(Timed.class), timer);

...it would be nice to simply write:

  bindInterceptor(Matchers.any(), Matchers.annotatedWith(Timed.class),
Timer.class);

_Original issue: http://code.google.com/p/google-guice/issues/detail?id=465_

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.