org.LexGrid.LexBIG.caCore.connection.orm.utils
Class LexEVSClassCache

java.lang.Object
  extended by gov.nih.nci.system.util.ClassCache
      extended by org.LexGrid.LexBIG.caCore.connection.orm.utils.LexEVSClassCache

public class LexEVSClassCache
extends gov.nih.nci.system.util.ClassCache


Field Summary
private  List<LexEVSDAO> daoList
           
private static org.apache.log4j.Logger log
           
private  List<DAOSelectionStrategy> selectionStrategies
           
 
Constructor Summary
LexEVSClassCache()
          Constructor for creating an empty ClassCache.
LexEVSClassCache(DAOListFactory listFactory)
          Constructs a Cache of Class and Hibernate information given.
 
Method Summary
private  List<LexEVSDAO> applySelectionStrategy(List<LexEVSDAO> daoList, gov.nih.nci.system.dao.Request request, QueryOptions queryOptions)
           
private  List<LexEVSDAO> getAllAvailableDAOs()
           
 gov.nih.nci.system.dao.DAO getDAOForClass(String qualClassName)
           
 List getDaoList()
           
 List getDaoList(gov.nih.nci.system.dao.Request request)
           
 List getDaoList(gov.nih.nci.system.dao.Request request, QueryOptions queryOptions)
           
 List<DAOSelectionStrategy> getSelectionStrategies()
           
 boolean isCollection(String className, String attribName)
           
 void setDaoList(List daoList)
           
 void setSelectionStrategies(List<DAOSelectionStrategy> selectionStrategies)
           
 
Methods inherited from class gov.nih.nci.system.util.ClassCache
getAllFieldNames, getAllFields, getAllPackageNames, getAllQualClassNames, getAllUnqualClassNames, getAssociations, getAssociationType, getClassFromCache, getDataType, getFields, getFieldsOfType, getFieldsOfTypeFromCache, getNonPrimitiveFields, getPkgClassNames, getPkgNameForClass, getQualifiedClassName, getReturnType, getReturnType, getSettersForTypeFromCache, getSubClassNames, isClassNameValid, isPackageNameValid, isSearchable, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

log

private static org.apache.log4j.Logger log

daoList

private List<LexEVSDAO> daoList

selectionStrategies

private List<DAOSelectionStrategy> selectionStrategies
Constructor Detail

LexEVSClassCache

public LexEVSClassCache(DAOListFactory listFactory)
                 throws gov.nih.nci.system.dao.DAOException
Constructs a Cache of Class and Hibernate information given.

Parameters:
listFactory - The DAO List Factory that is providing the DAOs for this Cache.
Throws:
gov.nih.nci.system.dao.DAOException

LexEVSClassCache

public LexEVSClassCache()
                 throws gov.nih.nci.system.dao.DAOException
Constructor for creating an empty ClassCache. Note: To populate this Cache, you must explicitly call 'setDaoList' -- otherwise this Cache will not be initialized. For most purposes, passing in the DAOListFactory is the preferred way of constructing this class, that way it will automatically be initialized. Use this constructor if you want to populate this Cache later, or not at all (for example, for disabling caCORE SDK functionality in LexEVSAPI).

Throws:
gov.nih.nci.system.dao.DAOException
Method Detail

setDaoList

public void setDaoList(List daoList)
Overrides:
setDaoList in class gov.nih.nci.system.util.ClassCache

getDaoList

public List getDaoList()
Overrides:
getDaoList in class gov.nih.nci.system.util.ClassCache

getDaoList

public List getDaoList(gov.nih.nci.system.dao.Request request,
                       QueryOptions queryOptions)
                throws SelectionStrategyException
Throws:
SelectionStrategyException

getDaoList

public List getDaoList(gov.nih.nci.system.dao.Request request)
                throws SelectionStrategyException
Throws:
SelectionStrategyException

isCollection

public boolean isCollection(String className,
                            String attribName)
                     throws gov.nih.nci.system.dao.QueryException
Overrides:
isCollection in class gov.nih.nci.system.util.ClassCache
Throws:
gov.nih.nci.system.dao.QueryException

applySelectionStrategy

private List<LexEVSDAO> applySelectionStrategy(List<LexEVSDAO> daoList,
                                               gov.nih.nci.system.dao.Request request,
                                               QueryOptions queryOptions)
                                        throws SelectionStrategyException
Throws:
SelectionStrategyException

getAllAvailableDAOs

private List<LexEVSDAO> getAllAvailableDAOs()

getSelectionStrategies

public List<DAOSelectionStrategy> getSelectionStrategies()

setSelectionStrategies

public void setSelectionStrategies(List<DAOSelectionStrategy> selectionStrategies)

getDAOForClass

public gov.nih.nci.system.dao.DAO getDAOForClass(String qualClassName)
Overrides:
getDAOForClass in class gov.nih.nci.system.util.ClassCache