Class OAuth2ServiceProviderRegistryImpl
java.lang.Object
org.nuxeo.runtime.model.DefaultComponent
org.nuxeo.ecm.platform.oauth2.providers.OAuth2ServiceProviderRegistryImpl
- All Implemented Interfaces:
OAuth2ServiceProviderRegistry
,Adaptable
,Component
,Extensible
,TimestampedService
public class OAuth2ServiceProviderRegistryImpl
extends DefaultComponent
implements OAuth2ServiceProviderRegistry
Implementation of the
OAuth2ServiceProviderRegistry
. The storage backend is a SQL Directory.-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
static final String
Registry of contributed providers.static final String
Fields inherited from class org.nuxeo.runtime.model.DefaultComponent
lastModified, name
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionaddProvider
(String serviceName, String description, String tokenServerURL, String authorizationServerURL, String userAuthorizationURL, String clientId, String clientSecret, List<String> scopes, Boolean isEnabled) addProvider
(String serviceName, String description, String tokenServerURL, String authorizationServerURL, String clientId, String clientSecret, List<String> scopes) protected OAuth2ServiceProvider
buildProvider
(DocumentModel entry) Instantiates the provider merging the contribution and the directory entryvoid
deleteProvider
(String serviceName) getProvider
(String serviceName) protected DocumentModel
getProviderDocModel
(String serviceName) protected List<DocumentModel>
queryProviders
(Map<String, Serializable> filter, int limit) void
registerContribution
(Object contribution, String extensionPoint, ComponentInstance contributor) protected void
void
start
(ComponentContext context) Start the component.updateProvider
(String serviceName, OAuth2ServiceProvider provider) Methods inherited from class org.nuxeo.runtime.model.DefaultComponent
activate, addRuntimeMessage, addRuntimeMessage, deactivate, getAdapter, getDescriptor, getDescriptors, getLastModified, getRegistry, register, registerExtension, setLastModified, setModifiedNow, setName, stop, unregister, unregisterContribution, unregisterExtension
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.nuxeo.runtime.model.Component
getApplicationStartedOrder
-
Field Details
-
PROVIDER_EP
- See Also:
-
DIRECTORY_NAME
- See Also:
-
SCHEMA
- See Also:
-
registry
Registry of contributed providers. These providers can extend and/or override the default provider class.
-
-
Constructor Details
-
OAuth2ServiceProviderRegistryImpl
public OAuth2ServiceProviderRegistryImpl()
-
-
Method Details
-
getProviderDocModel
-
getProvider
- Specified by:
getProvider
in interfaceOAuth2ServiceProviderRegistry
-
getProviders
- Specified by:
getProviders
in interfaceOAuth2ServiceProviderRegistry
-
addProvider
public OAuth2ServiceProvider addProvider(String serviceName, String description, String tokenServerURL, String authorizationServerURL, String clientId, String clientSecret, List<String> scopes) - Specified by:
addProvider
in interfaceOAuth2ServiceProviderRegistry
-
addProvider
public OAuth2ServiceProvider addProvider(String serviceName, String description, String tokenServerURL, String authorizationServerURL, String userAuthorizationURL, String clientId, String clientSecret, List<String> scopes, Boolean isEnabled) - Specified by:
addProvider
in interfaceOAuth2ServiceProviderRegistry
-
updateProvider
- Specified by:
updateProvider
in interfaceOAuth2ServiceProviderRegistry
-
deleteProvider
- Specified by:
deleteProvider
in interfaceOAuth2ServiceProviderRegistry
-
queryProviders
-
buildProvider
Instantiates the provider merging the contribution and the directory entry -
registerContribution
public void registerContribution(Object contribution, String extensionPoint, ComponentInstance contributor) - Overrides:
registerContribution
in classDefaultComponent
-
start
Description copied from interface:Component
Start the component. This method is called after all the components were resolved and activated- Specified by:
start
in interfaceComponent
- Overrides:
start
in classDefaultComponent
-
registerCustomProviders
protected void registerCustomProviders()
-