Package jetbrains.buildServer.spring
Class SpringSubContainerFactoryImpl.SpringContextImpl
- java.lang.Object
-
- jetbrains.buildServer.spring.SpringSubContainerFactoryImpl.SpringContextImpl
-
- All Implemented Interfaces:
ServiceLocator
,SpringContext
,jetbrains.buildServer.util.Disposable
- Enclosing class:
- SpringSubContainerFactoryImpl
public static class SpringSubContainerFactoryImpl.SpringContextImpl extends java.lang.Object implements SpringContext
-
-
Constructor Summary
Constructors Constructor Description SpringContextImpl(jetbrains.buildServer.spring.SpringSubContainerFactoryImpl.TeamCitySpringSubContainer container)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
dispose()
<T> T
findSingletonService(java.lang.Class<T> serviceClass)
Searches for singleton service of specified type<T> java.util.Collection<T>
getServices(java.lang.Class<T> serviceClass)
Searches for all bean instances of type<T> T
getSingletonService(java.lang.Class<T> serviceClass)
Searches for singleton service of specified type
-
-
-
Method Detail
-
getSingletonService
@NotNull public <T> T getSingletonService(@NotNull java.lang.Class<T> serviceClass) throws ServiceNotFoundException
Description copied from interface:ServiceLocator
Searches for singleton service of specified type- Specified by:
getSingletonService
in interfaceServiceLocator
- Parameters:
serviceClass
- type of the service- Returns:
- found service, never null
- Throws:
ServiceNotFoundException
- if specified service was not found or if more than one service found
-
findSingletonService
public <T> T findSingletonService(@NotNull java.lang.Class<T> serviceClass)
Description copied from interface:ServiceLocator
Searches for singleton service of specified type- Specified by:
findSingletonService
in interfaceServiceLocator
- Parameters:
serviceClass
- type of the service- Returns:
- found service or null if there's no such service
-
getServices
@NotNull public <T> java.util.Collection<T> getServices(@NotNull java.lang.Class<T> serviceClass)
Description copied from interface:ServiceLocator
Searches for all bean instances of type- Specified by:
getServices
in interfaceServiceLocator
- Parameters:
serviceClass
- - type to search- Returns:
- collection of classes that implements T
-
dispose
public void dispose()
- Specified by:
dispose
in interfacejetbrains.buildServer.util.Disposable
-
-