org.opensubsystems.security.utils
Class TestUserDatabaseFactoryUtils

java.lang.Object
  extended by org.opensubsystems.core.persist.db.DatabaseFactoryImpl
      extended by org.opensubsystems.security.utils.TestUserDatabaseFactoryUtils
All Implemented Interfaces:
org.opensubsystems.core.persist.db.DatabaseFactory

public class TestUserDatabaseFactoryUtils
extends org.opensubsystems.core.persist.db.DatabaseFactoryImpl

Data factory to retrieve and manipulate users in persistence store. This class is used as utilities for jUnit tests to provide manual cascade deleting.

Version:
$Id: TestUserDatabaseFactoryUtils.java,v 1.14 2007/01/07 06:15:07 bastafidli Exp $
Author:
Julo Legeny
Code reviewer:
, TODO: Review this code

Field Summary
protected  org.opensubsystems.security.persist.db.UserDatabaseSchema m_schema
          Schema to use to execute database dependent operations.
 
Fields inherited from class org.opensubsystems.core.persist.db.DatabaseFactoryImpl
m_connectionFactory, m_iConcurrencySelectListResultSet, m_iDataType, m_iTypeSelectListResultSet, m_transactionFactory
 
Constructor Summary
TestUserDatabaseFactoryUtils()
          Default constructor.
 
Method Summary
 void deleteUserCascadeManual(java.sql.Connection cntConnection, int iId)
          Method for deleting user and all his sessions, roles and access rights.
 void deleteUserCascadeManual(int iId)
          Method for deleting user and all his sessions, roles and access rights.
 void deleteUserCascadeManualUsingLike(java.lang.String strLikeClause)
          Method for deleting user and all his belonging sessions, roles and access rights.
 org.opensubsystems.core.data.DataObject load(java.sql.ResultSet rsQueryResults, int initialIndex)
          
 
Methods inherited from class org.opensubsystems.core.persist.db.DatabaseFactoryImpl
getConcurrencySelectListResultSet, getDataType, getTypeSelectListResultSet
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

m_schema

protected org.opensubsystems.security.persist.db.UserDatabaseSchema m_schema
Schema to use to execute database dependent operations.

Constructor Detail

TestUserDatabaseFactoryUtils

public TestUserDatabaseFactoryUtils()
                             throws org.opensubsystems.core.error.OSSException
Default constructor.

Throws:
org.opensubsystems.core.error.OSSException - - an error has occured
Method Detail

load

public org.opensubsystems.core.data.DataObject load(java.sql.ResultSet rsQueryResults,
                                                    int initialIndex)
                                             throws org.opensubsystems.core.error.OSSDatabaseAccessException

Throws:
org.opensubsystems.core.error.OSSDatabaseAccessException

deleteUserCascadeManual

public void deleteUserCascadeManual(int iId)
                             throws org.opensubsystems.core.error.OSSException
Method for deleting user and all his sessions, roles and access rights. It is neccessary to be include all security db tables.

Parameters:
iId - - ID of the user
Throws:
org.opensubsystems.core.error.OSSException - - error occured during deleting

deleteUserCascadeManual

public void deleteUserCascadeManual(java.sql.Connection cntConnection,
                                    int iId)
                             throws org.opensubsystems.core.error.OSSException
Method for deleting user and all his sessions, roles and access rights. It is neccessary to be include all security db tables.

Parameters:
cntConnection - - database connection to use
iId - - ID of the user
Throws:
org.opensubsystems.core.error.OSSException - - error occured during deleting

deleteUserCascadeManualUsingLike

public void deleteUserCascadeManualUsingLike(java.lang.String strLikeClause)
                                      throws org.opensubsystems.core.error.OSSException
Method for deleting user and all his belonging sessions, roles and access rights. It is neccessary to be present all security db tables.

Parameters:
strLikeClause - - LIKE clause the users are specified by
Throws:
org.opensubsystems.core.error.OSSException - - error occured during deleting


Copyright © 2003 - 2006 OpenSubsystems s.r.o.