public class HK2ManagedObjectLocator extends Object implements ManagedObjectLocator
ManagedObjectLocator that uses Binder HK2 Modules to discover the Managed objects in the TopicOrientedApplication.| Modifier and Type | Field and Description |
|---|---|
static String |
PROP_ENABLE_HK2_IMMEDIATE_SCOPE
Property used to control whether the Immediate scrope is enabled on ServiceLocators.
|
static boolean |
PROP_ENABLE_HK2_IMMEDIATE_SCOPE_DEFAULT
The default value for
PROP_ENABLE_HK2_IMMEDIATE_SCOPE (false). |
protected Tracer |
tracer |
| Constructor and Description |
|---|
HK2ManagedObjectLocator(TopicOrientedApplication application,
String applicationName,
List<org.glassfish.hk2.utilities.Binder> applicationModules)
Constructs an
HK2ManagedObjectLocator. |
| Modifier and Type | Method and Description |
|---|---|
protected List<org.glassfish.hk2.utilities.Binder> |
createPlatformModules()
Construct the Platform Modules.
|
protected org.glassfish.hk2.api.ServiceLocator |
createServiceLocator(String applicationName)
Construct the
ServiceLocator for the TopicOrientedApplication. |
void |
destroy()
Destroy the Application Service Locator and any
Managed Objects it may
have created. |
org.glassfish.hk2.api.ServiceLocator |
getApplicationServiceLocator()
Get the Application Service Locator.
|
void |
locateManagedObjects(Set<Object> managedObjects) |
public static final String PROP_ENABLE_HK2_IMMEDIATE_SCOPE
Property name: "nv.toa.hk2.enableimmediatescope"
Default value: false
public static final boolean PROP_ENABLE_HK2_IMMEDIATE_SCOPE_DEFAULT
PROP_ENABLE_HK2_IMMEDIATE_SCOPE (false).protected final Tracer tracer
public HK2ManagedObjectLocator(TopicOrientedApplication application, String applicationName, List<org.glassfish.hk2.utilities.Binder> applicationModules)
HK2ManagedObjectLocator.application - The TopicOrientedApplication that owns this locator.applicationName - The name of the application (which is passed to createServiceLocator(String).applicationModules - The List of Binderspublic void locateManagedObjects(Set<Object> managedObjects) throws Exception
locateManagedObjects in interface ManagedObjectLocatorExceptionprotected List<org.glassfish.hk2.utilities.Binder> createPlatformModules()
TopicOrientedApplication.protected org.glassfish.hk2.api.ServiceLocator createServiceLocator(String applicationName)
ServiceLocator for the TopicOrientedApplication.applicationName - The human-readable name of the TopicOrientedApplication. This should be used as the name for the ServiceLocator.ServiceLocator for the TopicOrientedApplicationpublic void destroy()
Managed Objects it may
have created.public org.glassfish.hk2.api.ServiceLocator getApplicationServiceLocator()
TopicOrientedApplication is provided with its own
ServiceLocator that will be different from that used by any other TopicOrientedApplication.Copyright © 2016 N5 Technologies, Inc. All Rights Reserved.