Comment #8 on issue 131 by sberlin: partial injection a.k.a. factory
generation
http://code.google.com/p/google-guice/issues/detail?id=131
Is there any thought to keeping @Assisted support (for simple use-cases)
and mapping
annotation-less params in the factory to the assisted parameters? That is,
Bean {
@Inject Bean(@Assisted String first, @Assisted String last, Service
service) { ... }
}
BeanFactory {
Bean createBean(String first, String last);
}
It could internally use a UniqueAnnotation to match up parameters that have
duplicate types.
I ask because it seems like it'd become a bit redundant in many cases to
have to
specify the annotations both in the Bean & the BeanFactory whenever you
want to pass
two of the same kind of parameter. It's definitely useful -- kind of like
parameter
naming in other languages -- but I find the current AssistedInject's
behaviour of
picking params in order to be spot-on most of the time.
(You can ignore this if the idea is to include Daniel's patch only as an
enhancement, not a replacement, of AssistedInject.)
--
You received this message because you are listed in the owner
or CC fields of this issue, or because you starred this issue.
You may adjust your issue notification preferences at:
http://code.google.com/hosting/settings
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"google-guice-dev" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/google-guice-dev?hl=en
-~----------~----~----~----~------~----~------~--~---