Class AbstractAuthenticator
- java.lang.Object
-
- org.springframework.extensions.webscripts.connector.AbstractAuthenticator
-
- All Implemented Interfaces:
org.springframework.beans.factory.Aware,org.springframework.context.ApplicationContextAware,Authenticator
- Direct Known Subclasses:
ActivitiAuthenticator,AlfrescoAuthenticator
public abstract class AbstractAuthenticator extends java.lang.Object implements Authenticator, org.springframework.context.ApplicationContextAware
Implementation of an Authenticator base class.This abstract implementation provides helper methods for post-processing response elements such as headers.
- Author:
- muzquiano, Kevin Roast
- See Also:
AbstractConnector
-
-
Constructor Summary
Constructors Constructor Description AbstractAuthenticator()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected RemoteClientbuildRemoteClient(java.lang.String endpoint)Build a Remote Client instance by retrieving and configuring the "connector.remoteclient" bean.protected ConnectorServicegetConnectorService()Helper to return the "connector.service" bean for concrete implementations to make use ofprotected voidprocessResponse(Response response, ConnectorSession connectorSession)Retrieves headers from response and stores onto the Connector SessionvoidsetApplicationContext(org.springframework.context.ApplicationContext applicationContext)Sets the Spring application context-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.springframework.extensions.webscripts.connector.Authenticator
authenticate, isAuthenticated
-
-
-
-
Method Detail
-
setApplicationContext
public void setApplicationContext(org.springframework.context.ApplicationContext applicationContext)
Sets the Spring application context- Specified by:
setApplicationContextin interfaceorg.springframework.context.ApplicationContextAware- Parameters:
applicationContext- the Spring application context
-
getConnectorService
protected ConnectorService getConnectorService()
Helper to return the "connector.service" bean for concrete implementations to make use of- Returns:
- ConnectorService
-
buildRemoteClient
protected RemoteClient buildRemoteClient(java.lang.String endpoint)
Build a Remote Client instance by retrieving and configuring the "connector.remoteclient" bean.- Parameters:
endpoint- Configured Endpoint ID for the remote client instance
-
processResponse
protected void processResponse(Response response, ConnectorSession connectorSession)
Retrieves headers from response and stores onto the Connector Session- Parameters:
response- ResponseconnectorSession- ConnectorSession
-
-