org.sakaiproject.entitybroker.util.devhelper
Class DeveloperHelperServiceMock
java.lang.Object
org.sakaiproject.entitybroker.util.devhelper.AbstractDeveloperHelperService
org.sakaiproject.entitybroker.util.devhelper.DeveloperHelperServiceMock
- All Implemented Interfaces:
- DeveloperHelperService
public class DeveloperHelperServiceMock
- extends AbstractDeveloperHelperService
This is the Mock for the developer helper service,
allows the service to always be available even when someone has not implemented it for the
system that is using EB
- Author:
- Aaron Zeckoski (azeckoski @ gmail.com)
|
Method Summary |
|
getConfigurationSetting(String settingName,
T defaultValue)
|
String |
getCurrentLocationId()
|
String |
getCurrentLocationReference()
|
String |
getCurrentToolReference()
|
String |
getCurrentUserId()
|
String |
getCurrentUserReference()
|
Set<String> |
getEntityReferencesForUserAndPermission(String userReference,
String permission)
|
String |
getPortalURL()
|
String |
getServerURL()
|
SakaiToolData |
getToolData(String toolRegistrationId,
String locationReference)
|
String |
getToolViewURL(String toolRegistrationId,
String localView,
Map<String,String> parameters,
String locationReference)
|
Set<String> |
getUserReferencesForEntityReference(String reference,
String permission)
|
String |
getUserRefFromUserEid(String userEid)
|
boolean |
isUserAdmin(String userReference)
|
boolean |
isUserAllowedInEntityReference(String userReference,
String permission,
String reference)
|
void |
registerPermission(String permission)
|
String |
restoreCurrentUser()
|
String |
setCurrentUser(String userReference)
|
| Methods inherited from class org.sakaiproject.entitybroker.util.devhelper.AbstractDeveloperHelperService |
cloneBean, convert, copyBean, decodeData, encodeData, entityExists, fetchEntity, fireEvent, getCurrentLocale, getEntityRESTProvider, getEntityURL, getLocationIdFromRef, getLocationReferenceURL, getMessage, getStartingLocationReference, getToolIdFromToolRef, getUserHomeLocationReference, getUserHomeLocationURL, getUserIdFromRef, getUserRefFromUserId, isEntityRequestInternal, populate, setEntityBroker, setEntityBrokerManager, setEntityProperties, setEntityRESTProvider, setRequestStorage |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
defaultLocationId
public static String defaultLocationId
defaultLocationRef
public static String defaultLocationRef
defaultToolId
public static String defaultToolId
defaultToolRef
public static String defaultToolRef
defaultUserId
public static String defaultUserId
defaultUserEid
public static String defaultUserEid
defaultUserRef
public static String defaultUserRef
currentUserRef
public static String currentUserRef
lastCurrentUser
public static String lastCurrentUser
defaultServerURL
public static String defaultServerURL
defaultPortalURL
public static String defaultPortalURL
defaultEntityRef
public static String defaultEntityRef
defaultPermAllowed
public static String defaultPermAllowed
registeredPerms
public static HashSet<String> registeredPerms
DeveloperHelperServiceMock
public DeveloperHelperServiceMock()
getConfigurationSetting
public <T> T getConfigurationSetting(String settingName,
T defaultValue)
getCurrentLocationId
public String getCurrentLocationId()
getCurrentLocationReference
public String getCurrentLocationReference()
- Specified by:
getCurrentLocationReference in interface DeveloperHelperService- Overrides:
getCurrentLocationReference in class AbstractDeveloperHelperService
getCurrentToolReference
public String getCurrentToolReference()
getCurrentUserId
public String getCurrentUserId()
restoreCurrentUser
public String restoreCurrentUser()
setCurrentUser
public String setCurrentUser(String userReference)
getCurrentUserReference
public String getCurrentUserReference()
- Specified by:
getCurrentUserReference in interface DeveloperHelperService- Overrides:
getCurrentUserReference in class AbstractDeveloperHelperService
getPortalURL
public String getPortalURL()
getServerURL
public String getServerURL()
getToolData
public SakaiToolData getToolData(String toolRegistrationId,
String locationReference)
getToolViewURL
public String getToolViewURL(String toolRegistrationId,
String localView,
Map<String,String> parameters,
String locationReference)
getUserRefFromUserEid
public String getUserRefFromUserEid(String userEid)
getEntityReferencesForUserAndPermission
public Set<String> getEntityReferencesForUserAndPermission(String userReference,
String permission)
getUserReferencesForEntityReference
public Set<String> getUserReferencesForEntityReference(String reference,
String permission)
isUserAdmin
public boolean isUserAdmin(String userReference)
isUserAllowedInEntityReference
public boolean isUserAllowedInEntityReference(String userReference,
String permission,
String reference)
registerPermission
public void registerPermission(String permission)
Copyright © 2007-2012 CARET, University of Cambridge. All Rights Reserved.