org.sakaiproject.component.legacy.user
Class DbUserService

java.lang.Object
  extended byorg.sakaiproject.component.legacy.user.BaseUserDirectoryService
      extended byorg.sakaiproject.component.legacy.user.DbUserService
All Implemented Interfaces:
EntityProducer, StorageUser, UserDirectoryService, UserFactory

public class DbUserService
extends BaseUserDirectoryService

DbCachedUserService is an extension of the BaseUserService with a database storage backed up by an in-memory cache.

Version:
$Revision: 5554 $
Author:
University of Michigan, Sakai Software Development Team

Nested Class Summary
protected  class DbUserService.DbStorage
          Covers for the BaseXmlFileStorage, providing User and UserEdit parameters
protected  class DbUserService.DbStorageOld
          Covers for the BaseXmlFileStorage, providing User and UserEdit parameters
 
Nested classes inherited from class org.sakaiproject.component.legacy.user.BaseUserDirectoryService
BaseUserDirectoryService.BaseUserEdit, BaseUserDirectoryService.Storage
 
Nested classes inherited from class org.sakaiproject.service.legacy.entity.EntityProducer
EntityProducer.ChangeType
 
Field Summary
protected  boolean m_autoDdl
          Configuration: to run the ddl on init or not.
protected  boolean m_checkOld
          Configuration: check the old table, too.
protected  boolean m_convertOld
          Set if we are to run the from-old conversion.
protected  String[] m_fieldNames
          All fields.
protected  String m_idFieldName
          ID field.
protected  String m_propTableName
          Table name for properties.
protected  String m_sortField1
          SORT field 1.
protected  String m_sortField2
          SORT field 2.
protected  SqlService m_sqlService
          Dependency: SqlService
protected  String m_tableName
          Table name for users.
protected  boolean m_useExternalLocks
          If true, we do our locks in the remote database, otherwise we do them here.
 
Fields inherited from class org.sakaiproject.component.legacy.user.BaseUserDirectoryService
m_anon, m_cacheCleanerSeconds, m_cacheSeconds, m_callCache, m_caseSensitiveId, M_curUserKey, m_entityManager, m_logger, m_provider, m_relativeAccessPoint, m_serverConfigurationService, m_storage
 
Fields inherited from interface org.sakaiproject.service.legacy.user.UserDirectoryService
REFERENCE_ROOT, SECURE_ADD_USER, SECURE_REMOVE_USER, SECURE_UPDATE_USER_ANY, SECURE_UPDATE_USER_OWN, SERVICE_NAME
 
Constructor Summary
DbUserService()
           
 
Method Summary
protected  void convertOld()
          Create a new table record for all old table records found, and delete the old.
 void init()
          Final initialization, once all dependencies are set.
protected  BaseUserDirectoryService.Storage newStorage()
          Construct a Storage object.
 void setAutoDdl(String value)
          Configuration: to run the ddl on init or not.
 void setCheckOld(String value)
          Configuration: set the locks-in-db
 void setConvertOld(String value)
          Configuration: run the from-old conversion.
 void setExternalLocks(String value)
          Configuration: set the external locks value.
 void setSqlService(SqlService service)
          Dependency: SqlService.
 void setTableName(String name)
          Configuration: set the table name
 
Methods inherited from class org.sakaiproject.component.legacy.user.BaseUserDirectoryService
addLiveProperties, addLiveUpdateProperties, addUser, addUser, allowAddUser, allowRemoveUser, allowUpdateUser, archive, authenticate, authenticateViaProvider, cancelEdit, cleanId, commitEdit, countSearchUsers, countUsers, destroy, destroyAuthentication, editUser, findUser, findUserByEid, findUsersByEmail, getAccessPoint, getAnonymousUser, getCurrentUser, getDate, getEntity, getEntityAuthzGroups, getEntityDescription, getEntityResourceProperties, getEntityUrl, getHttpAccess, getLabel, getOwnerId, getUser, getUserByEid, getUsers, getUsers, getUsers, importEntities, isDraft, merge, mergeUser, newContainer, newContainer, newContainer, newContainerEdit, newContainerEdit, newContainerEdit, newResource, newResource, newResource, newResourceEdit, newResourceEdit, newResourceEdit, newUser, parseEntityReference, removeUser, searchUsers, setCacheCleanerMinutes, setCacheMinutes, setCaseSensitiveId, setEntityManager, setLogger, setProvider, setServerConfigurationService, storageFields, syncWithSiteChange, unlock, unlock2, unlockCheck, unlockCheck2, userId, userReference, willArchiveMerge, willImport
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

m_tableName

protected String m_tableName
Table name for users.


m_propTableName

protected String m_propTableName
Table name for properties.


m_idFieldName

protected String m_idFieldName
ID field.


m_sortField1

protected String m_sortField1
SORT field 1.


m_sortField2

protected String m_sortField2
SORT field 2.


m_fieldNames

protected String[] m_fieldNames
All fields.


m_sqlService

protected SqlService m_sqlService
Dependency: SqlService


m_useExternalLocks

protected boolean m_useExternalLocks
If true, we do our locks in the remote database, otherwise we do them here.


m_convertOld

protected boolean m_convertOld
Set if we are to run the from-old conversion.


m_checkOld

protected boolean m_checkOld
Configuration: check the old table, too.


m_autoDdl

protected boolean m_autoDdl
Configuration: to run the ddl on init or not.

Constructor Detail

DbUserService

public DbUserService()
Method Detail

setSqlService

public void setSqlService(SqlService service)
Dependency: SqlService.

Parameters:
service - The SqlService.

setTableName

public void setTableName(String name)
Configuration: set the table name


setExternalLocks

public void setExternalLocks(String value)
Configuration: set the external locks value.

Parameters:
value - The external locks value.

setConvertOld

public void setConvertOld(String value)
Configuration: run the from-old conversion.

Parameters:
value - The conversion desired value.

setCheckOld

public void setCheckOld(String value)
Configuration: set the locks-in-db

Parameters:
value - The locks-in-db value.

setAutoDdl

public void setAutoDdl(String value)
Configuration: to run the ddl on init or not.

Parameters:
value - the auto ddl value.

init

public void init()
Final initialization, once all dependencies are set.

Overrides:
init in class BaseUserDirectoryService

newStorage

protected BaseUserDirectoryService.Storage newStorage()
Construct a Storage object.

Specified by:
newStorage in class BaseUserDirectoryService
Returns:
The new storage object.

convertOld

protected void convertOld()
Create a new table record for all old table records found, and delete the old.