Class ContextDebugService
- java.lang.Object
-
- ru.vyarus.dropwizard.guice.module.jersey.debug.service.ContextDebugService
-
@Singleton public class ContextDebugService extends java.lang.ObjectDebug service checks and collect information on jersey (and HK2) related types instantiation. Actual bean instantiation detection by guice or HK2 is performed by specific listeners. Service only checks correctness and tracks instantiated objects.Only objects installed by
JerseyInstallerinstallers are tracked.- Since:
- 15.01.2016
-
-
Constructor Summary
Constructors Constructor Description ContextDebugService(javax.inject.Provider<ExtensionsHolder> holder, Options options)Create jersey debug service.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.List<java.lang.Class<?>>getGuiceManaged()java.util.List<java.lang.Class<?>>getHkManaged()java.util.List<java.lang.Class<?>>getManagedTypes()voidguiceManage(java.lang.Class<?> type)Called by specific guice provision listener to check if bean is properly instantiated by guice.voidhkManage(java.lang.Class<?> type)Called by specific HK2 lifecycle listener to check if bean is properly instantiated by HK2.
-
-
-
Constructor Detail
-
ContextDebugService
@Inject public ContextDebugService(javax.inject.Provider<ExtensionsHolder> holder, Options options)
Create jersey debug service.- Parameters:
holder- extensions holderoptions- options
-
-
Method Detail
-
getManagedTypes
public java.util.List<java.lang.Class<?>> getManagedTypes()
- Returns:
- list of all types that must be tracked
-
hkManage
public void hkManage(java.lang.Class<?> type)
Called by specific HK2 lifecycle listener to check if bean is properly instantiated by HK2.- Parameters:
type- instantiated bean type
-
guiceManage
public void guiceManage(java.lang.Class<?> type)
Called by specific guice provision listener to check if bean is properly instantiated by guice.- Parameters:
type- instantiated bean type
-
getHkManaged
public java.util.List<java.lang.Class<?>> getHkManaged()
- Returns:
- classes of all tracked beans instantiated by HK2 (so far)
-
getGuiceManaged
public java.util.List<java.lang.Class<?>> getGuiceManaged()
- Returns:
- classes of all tracked beans instantiated by guice (so far)
-
-