Hi,
I'm not sure if this is a good idea.
Am 28.08.2015 um 17:07 schrieb Thiago H de Paula Figueiredo:
when more than one service matches the
requested service, but only one of them has the @Primary annotation from
tapestry5-annotations, return it.
If the registry contains multiple implementations of the same interface,
there's usually a reason for it and the developer should need to think
about which implementation is to be injected where. Also, it makes the
code easier to understand if there is an explicit marker annotation
along with @Inject.
It should however be possible to override ServiceInjectionProvider with
an implementation that behaves like that.
What do you guys think? It would be helpful specially for objects
contributed to a service configuration and you want them to be services
by themselves.
Isn't @Local usually sufficient for that use case?
Jochen
On Tue, 25 Aug 2015 10:15:45 -0300, Nathan Quirynen (JIRA)
<j...@apache.org> wrote:
Nathan Quirynen created TAP5-2491:
-------------------------------------
Summary: Default marker annotation
Key: TAP5-2491
URL: https://issues.apache.org/jira/browse/TAP5-2491
Project: Tapestry 5
Issue Type: Improvement
Components: tapestry-core
Affects Versions: 5.3.7
Reporter: Nathan Quirynen
Priority: Minor
It would be nice when making use of Marker annotations for tagging a
service, that a default marker value could be defined. So when no
marker annotation is added to the injection of the service this
defined default will be used.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@tapestry.apache.org
For additional commands, e-mail: dev-h...@tapestry.apache.org