org.sourceid.saml20.service.impl.localmemory
Class AccountLinkingServiceMapImpl

java.lang.Object
  extended by org.sourceid.saml20.service.impl.localmemory.AccountLinkingServiceMapImpl
All Implemented Interfaces:
AccountLinkingService

public class AccountLinkingServiceMapImpl
extends java.lang.Object
implements AccountLinkingService

A HashMap backed implementation of the AccountLinkingService. Not really for production use.

Author:
Brian Campbell

Constructor Summary
AccountLinkingServiceMapImpl()
           
 
Method Summary
 java.lang.String lookupLink(java.lang.String idpEntityId, java.lang.String authnAdapterId, java.lang.String externalIdentifier)
          Lookup a local user id keyed from he composite key of idpEntityId, authnaAdapterId, and externalIdentifier.
 void storeLink(java.lang.String localIdentifier, java.lang.String idpEntityId, java.lang.String authnAdapterId, java.lang.String externalIdentifier)
          Store the account link - an association of the composite key of idpEntityId, authnaAdapterId, and externalIdentifier to the localIdentifier.
 void terminateLink(java.lang.String idpEntityId, java.lang.String authnAdapterId, java.lang.String externalIdentifier)
          Terminate the account link identified by the he composite key of idpEntityId, authnaAdapterId, and externalIdentifier.
 void updateExternalId(java.lang.String newExternalIdentifier, java.lang.String idpEntityId, java.lang.String oldExternalIdentifier)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AccountLinkingServiceMapImpl

public AccountLinkingServiceMapImpl()
Method Detail

lookupLink

public java.lang.String lookupLink(java.lang.String idpEntityId,
                                   java.lang.String authnAdapterId,
                                   java.lang.String externalIdentifier)
                            throws AccountLinkingServiceException
Description copied from interface: AccountLinkingService
Lookup a local user id keyed from he composite key of idpEntityId, authnaAdapterId, and externalIdentifier.

Specified by:
lookupLink in interface AccountLinkingService
Parameters:
idpEntityId - the entity id of the IdP partner connection that issued the external identifier.
authnAdapterId - the id of the SpAuthenticationAdapter instance.
externalIdentifier - the external identifier sent by the IdP.
Returns:
the the local user id of the principal or null if no link exists.
Throws:
AccountLinkingServiceException - for any unexpected runtime problem that the implementation cannot handle.

storeLink

public void storeLink(java.lang.String localIdentifier,
                      java.lang.String idpEntityId,
                      java.lang.String authnAdapterId,
                      java.lang.String externalIdentifier)
               throws AccountLinkingServiceException
Description copied from interface: AccountLinkingService
Store the account link - an association of the composite key of idpEntityId, authnaAdapterId, and externalIdentifier to the localIdentifier.

Specified by:
storeLink in interface AccountLinkingService
Parameters:
localIdentifier - the the local user id of the principal.
idpEntityId - the entity id of the IdP partner connection that issued the external identifier.
authnAdapterId - the id of the SpAuthenticationAdapter instance.
externalIdentifier - the external identifier sent by the IdP.
Throws:
AccountLinkingServiceException - for any unexpected runtime problem that the implementation cannot handle.

updateExternalId

public void updateExternalId(java.lang.String newExternalIdentifier,
                             java.lang.String idpEntityId,
                             java.lang.String oldExternalIdentifier)
                      throws AccountLinkingServiceException
Throws:
AccountLinkingServiceException

terminateLink

public void terminateLink(java.lang.String idpEntityId,
                          java.lang.String authnAdapterId,
                          java.lang.String externalIdentifier)
                   throws AccountLinkingServiceException
Description copied from interface: AccountLinkingService
Terminate the account link identified by the he composite key of idpEntityId, authnaAdapterId, and externalIdentifier.

Specified by:
terminateLink in interface AccountLinkingService
Parameters:
idpEntityId - the entity id of the IdP partner connection that issued the external identifier.
authnAdapterId - the id of the SpAuthenticationAdapter instance.
externalIdentifier - the external identifier sent by the IdP.
Throws:
AccountLinkingServiceException - for any unexpected runtime problem that the implementation cannot handle.


Copyright 2007 Ping Identity Corp. All rights reserved.