T - the role typepublic class GenericProvider<T> extends Object implements javax.inject.Provider<T>
Provider field but no custom Provider has
been registered. The default behavior is simply to look up the Component role class when
Provider.get() is called. This is useful for example when you wish to do "lazy injection".| Modifier and Type | Field and Description |
|---|---|
protected ComponentManager |
componentManager |
| Constructor and Description |
|---|
GenericProvider(ComponentManager componentManager,
org.xwiki.component.internal.RoleHint<T> roleHint) |
protected ComponentManager componentManager
public GenericProvider(ComponentManager componentManager, org.xwiki.component.internal.RoleHint<T> roleHint)
componentManager - the Component Manager instance that we'll use to look up the Component Role during
Provider.get()roleHint - the Component Role and Hint that uniquely identify the Component we wish to provide forprotected T getInstance(Type type, String hint) throws ComponentLookupException
ComponentLookupExceptionCopyright © 2004–2015 XWiki. All rights reserved.