You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by haipeng du <ha...@gmail.com> on 2009/07/25 22:53:19 UTC
T5 object provider problem
For object provider, here is the java doc:
*Type Parameters:*T - *Parameters:*objectType - the expected object type
annotationProvider - provides access to annotations (typically, the field or
parameter to which an injection-related annotation is attached); annotations
on the field or parameter may also be used when resolving the desired object
locator - locator for the *context* in which the provider is being used *
Returns:*the requested object, or null if this object provider can not
supply an object The problem is here:
if my object provider really want to inject null to object, how could I do?
As I understand, if I return null, the IOC will try to find other providers
to inject it and throw exception. So I have no way to inject null to object.
That does not make sense at all.
Thanks.
--
Haipeng Du
Salt Lake City