@Service public class WebServiceLocator extends Object implements org.springframework.context.ApplicationContextAware
Modifier and Type | Method and Description |
---|---|
static <T> T |
findService(Class<T> serviceClass)
Get a service that has the given type.
|
static <T> T |
findService(String name,
Class<T> requiredType)
Get a service by name that has the given type.
|
BaseCommunoteAuthenticationProvider |
getInvitationProvider(String identifier) |
JsMessagesRegistry |
getJsMessagesRegistry() |
org.springframework.security.authentication.ProviderManager |
getProviderManager() |
<T> T |
getService(Class<T> requiredType)
Get a service that has the given type.
|
<T> T |
getService(String name,
Class<T> requiredType)
Get a service by name that has the given type.
|
StartpageRegistry |
getStartpageRegistry() |
org.springframework.context.ApplicationContext |
getWebApplicationContext() |
WidgetExtensionManagementRepository |
getWidgetExtensionManagementRepository() |
static WebServiceLocator |
instance()
The singleton instance
|
void |
setApplicationContext(org.springframework.context.ApplicationContext applicationContext) |
public static final <T> T findService(Class<T> serviceClass)
T
- the type of the servicerequiredType
- the type of the service to returnpublic static final <T> T findService(String name, Class<T> requiredType)
T
- the type of the servicename
- the name of the servicerequiredType
- the type of the service to returnpublic static WebServiceLocator instance()
public BaseCommunoteAuthenticationProvider getInvitationProvider(String identifier)
identifier
- Identifier of the provider to use. if null
the next possible provider
will be used.public JsMessagesRegistry getJsMessagesRegistry()
public org.springframework.security.authentication.ProviderManager getProviderManager()
public <T> T getService(Class<T> requiredType)
T
- the type of the servicerequiredType
- the type of the service to returnpublic <T> T getService(String name, Class<T> requiredType)
T
- the type of the servicename
- the name of the servicerequiredType
- the type of the service to returnpublic StartpageRegistry getStartpageRegistry()
public org.springframework.context.ApplicationContext getWebApplicationContext()
public WidgetExtensionManagementRepository getWidgetExtensionManagementRepository()
public void setApplicationContext(org.springframework.context.ApplicationContext applicationContext) throws org.springframework.beans.BeansException
setApplicationContext
in interface org.springframework.context.ApplicationContextAware
org.springframework.beans.BeansException
Copyright © 2019 Communote team. All rights reserved.