public final class ServiceManager
extends java.lang.Object
ComponentManager.getService(Class)
or ComponentManager.getServiceIfCreated(Class)
.Modifier and Type | Method and Description |
---|---|
static <T> NotNullLazyKey<T,Project> |
createLazyKey(java.lang.Class<? extends T> serviceClass)
Creates lazy caching key to store project-level service instance from
ComponentManager.getService(Class) . |
static <T> T |
getService(java.lang.Class<T> serviceClass) |
static <T> T |
getService(Project project,
java.lang.Class<T> serviceClass) |
static <T> T |
getServiceIfCreated(java.lang.Class<T> serviceClass) |
static <T> T |
getServiceIfCreated(Project project,
java.lang.Class<T> serviceClass) |
public static <T> T getService(java.lang.Class<T> serviceClass)
public static <T> T getService(Project project, java.lang.Class<T> serviceClass)
public static <T> T getServiceIfCreated(Project project, java.lang.Class<T> serviceClass)
public static <T> T getServiceIfCreated(java.lang.Class<T> serviceClass)
public static <T> NotNullLazyKey<T,Project> createLazyKey(java.lang.Class<? extends T> serviceClass)
ComponentManager.getService(Class)
.T
- Service class type.serviceClass
- Service class to create key for.