nl.surfnet.coin.csa.service.impl
Class CrmServiceNoop

java.lang.Object
  extended by nl.surfnet.coin.csa.service.impl.CrmServiceNoop
All Implemented Interfaces:
CrmService

public class CrmServiceNoop
extends Object
implements CrmService

No operation CrmService to be used in OpenConext


Constructor Summary
CrmServiceNoop()
           
 
Method Summary
 void evictCache()
           
 List<Account> getAccounts(boolean isInstitution)
          Get all institutions
 List<Article> getArticlesForServiceProviders(List<String> serviceProviderEntityIds)
          Get articles for the given serviceProviders.
 String getEndpoint()
           
 String getInstitutionName(String guid)
          Get the name of the institution in LMNG belonging to given GUID
 List<License> getLicensesForIdpAndSp(IdentityProvider identityProvider, String articleIdentifier)
          Gets a list with Licenses for the given identityProvider and services (lmngIdentifiers) which are valid on the given day
 List<License> getLicensesForIdpAndSps(IdentityProvider identityProvider, List<String> articleIdentifiers)
           
 Article getService(String guid)
          Get LMNG article by article ID
 String getServiceName(String lmngId)
          Get the name of the service/product in LMNG belonging to given GUID
 boolean isDebug()
           
 String performQuery(String rawQuery)
          Convenience method to run various queries
 void setDebug(boolean debug)
           
 void setEndpoint(String endpoint)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CrmServiceNoop

public CrmServiceNoop()
Method Detail

getLicensesForIdpAndSp

public List<License> getLicensesForIdpAndSp(IdentityProvider identityProvider,
                                            String articleIdentifier)
                                     throws LmngException
Description copied from interface: CrmService
Gets a list with Licenses for the given identityProvider and services (lmngIdentifiers) which are valid on the given day

Specified by:
getLicensesForIdpAndSp in interface CrmService
Parameters:
identityProvider - the identityProvider to get the licenses for
articleIdentifier - lmngIdentifier (belonging to SP's) where the licenses are for.
Returns:
a (possible) list of licenses
Throws:
LmngException - If connection or call fails (rethrows all exceptions)

getLicensesForIdpAndSps

public List<License> getLicensesForIdpAndSps(IdentityProvider identityProvider,
                                             List<String> articleIdentifiers)
                                      throws LmngException
Specified by:
getLicensesForIdpAndSps in interface CrmService
Throws:
LmngException

getArticlesForServiceProviders

public List<Article> getArticlesForServiceProviders(List<String> serviceProviderEntityIds)
                                             throws LmngException
Description copied from interface: CrmService
Get articles for the given serviceProviders.

Specified by:
getArticlesForServiceProviders in interface CrmService
Parameters:
serviceProviderEntityIds - list of ID's of serviceproviders to get the lmng article for
Returns:
a list of possible articles
Throws:
LmngException

getInstitutionName

public String getInstitutionName(String guid)
Description copied from interface: CrmService
Get the name of the institution in LMNG belonging to given GUID

Specified by:
getInstitutionName in interface CrmService
Parameters:
guid - guid of the IDP to check
Returns:
the name of the institution in LMNG

getService

public Article getService(String guid)
Description copied from interface: CrmService
Get LMNG article by article ID

Specified by:
getService in interface CrmService
Parameters:
guid - guid of the article
Returns:
the article found or null

getServiceName

public String getServiceName(String lmngId)
Description copied from interface: CrmService
Get the name of the service/product in LMNG belonging to given GUID

Specified by:
getServiceName in interface CrmService
Returns:

getAccounts

public List<Account> getAccounts(boolean isInstitution)
Description copied from interface: CrmService
Get all institutions

Specified by:
getAccounts in interface CrmService
Returns:
all accounts of the institutions / serviceproviders known in LMNG

performQuery

public String performQuery(String rawQuery)
Description copied from interface: CrmService
Convenience method to run various queries

Specified by:
performQuery in interface CrmService
Parameters:
rawQuery - the fetch string
Returns:
the raw response

evictCache

public void evictCache()
Specified by:
evictCache in interface CrmService

getEndpoint

public String getEndpoint()

setEndpoint

public void setEndpoint(String endpoint)

isDebug

public boolean isDebug()

setDebug

public void setDebug(boolean debug)


Copyright © 2013 SURFnet bv, The Netherlands. All Rights Reserved.