Package jetbrains.buildServer.spring
Class SpringSubContainerFactoryImpl.SpringContextImpl
- java.lang.Object
-
- jetbrains.buildServer.spring.SpringSubContainerFactoryImpl.SpringContextImpl
-
- All Implemented Interfaces:
ServiceLocator,SpringContext,Disposable
- Enclosing class:
- SpringSubContainerFactoryImpl
public static class SpringSubContainerFactoryImpl.SpringContextImpl extends 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 voiddispose()<T> TfindSingletonService(Class<T> serviceClass)Searches for singleton service of specified type<T> Collection<T>getServices(Class<T> serviceClass)Searches for all bean instances of type<T> TgetSingletonService(Class<T> serviceClass)Searches for singleton service of specified type
-
-
-
Method Detail
-
getSingletonService
@NotNull public <T> T getSingletonService(@NotNull Class<T> serviceClass) throws ServiceNotFoundExceptionDescription copied from interface:ServiceLocatorSearches for singleton service of specified type- Specified by:
getSingletonServicein 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 Class<T> serviceClass)Description copied from interface:ServiceLocatorSearches for singleton service of specified type- Specified by:
findSingletonServicein interfaceServiceLocator- Parameters:
serviceClass- type of the service- Returns:
- found service or null if there's no such service
-
getServices
@NotNull public <T> Collection<T> getServices(@NotNull Class<T> serviceClass)
Description copied from interface:ServiceLocatorSearches for all bean instances of type- Specified by:
getServicesin interfaceServiceLocator- Parameters:
serviceClass- - type to search- Returns:
- collection of classes that implements T
-
dispose
public void dispose()
- Specified by:
disposein interfaceDisposable
-
-