org.squashtest.csp.tm.internal.repository.hibernate
Class HibernateTestCaseFolderDao

java.lang.Object
  extended by org.squashtest.csp.tm.internal.repository.hibernate.HibernateDao<ENTITY_TYPE>
      extended by org.squashtest.csp.tm.internal.repository.hibernate.HibernateEntityDao<TestCaseFolder>
          extended by org.squashtest.csp.tm.internal.repository.hibernate.HibernateTestCaseFolderDao
All Implemented Interfaces:
EntityDao<TestCaseFolder>, FolderDao<TestCaseFolder,TestCaseLibraryNode>, TestCaseFolderDao

@Repository
public class HibernateTestCaseFolderDao
extends HibernateEntityDao<TestCaseFolder>
implements TestCaseFolderDao


Field Summary
 
Fields inherited from class org.squashtest.csp.tm.internal.repository.hibernate.HibernateDao
entityType
 
Constructor Summary
HibernateTestCaseFolderDao()
           
 
Method Summary
 List<TestCaseLibraryNode> findAllContentById(long folderId)
           
 List<TestCaseFolder> findAllFolders(List<Long> folderIds)
          will return a (non-null) list of test case folders given their ids
 TestCaseFolder findByContent(TestCaseLibraryNode node)
          Finds the folder which has the given node in its content.
 List<Long> findContentForList(List<Long> ids)
           
 List<String> findNamesInFolderStartingWith(long folderId, String nameStart)
           
 List<String> findNamesInLibraryStartingWith(long libraryId, String nameStart)
           
 List<Long[]> findPairedContentForList(List<Long> ids)
           
 List<Long> findTestCasesFolderIdsInFolderContent(long folderId)
           
 
Methods inherited from class org.squashtest.csp.tm.internal.repository.hibernate.HibernateEntityDao
findAllByIdList, findById, flush, getIdPropertyName, persist, persist, remove
 
Methods inherited from class org.squashtest.csp.tm.internal.repository.hibernate.HibernateDao
currentSession, executeEntityNamedQuery, executeListNamedQuery, executeListNamedQuery, executeListNamedQuery, getEntity, persistEntity, removeEntity
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.squashtest.csp.tm.internal.repository.EntityDao
findAllByIdList, findById, flush, persist, persist, remove
 

Constructor Detail

HibernateTestCaseFolderDao

public HibernateTestCaseFolderDao()
Method Detail

findAllContentById

public List<TestCaseLibraryNode> findAllContentById(long folderId)
Specified by:
findAllContentById in interface FolderDao<TestCaseFolder,TestCaseLibraryNode>

findByContent

public TestCaseFolder findByContent(TestCaseLibraryNode node)
Description copied from interface: FolderDao
Finds the folder which has the given node in its content.

Specified by:
findByContent in interface FolderDao<TestCaseFolder,TestCaseLibraryNode>
Returns:

findNamesInFolderStartingWith

public List<String> findNamesInFolderStartingWith(long folderId,
                                                  String nameStart)
Specified by:
findNamesInFolderStartingWith in interface FolderDao<TestCaseFolder,TestCaseLibraryNode>

findNamesInLibraryStartingWith

public List<String> findNamesInLibraryStartingWith(long libraryId,
                                                   String nameStart)
Specified by:
findNamesInLibraryStartingWith in interface FolderDao<TestCaseFolder,TestCaseLibraryNode>

findTestCasesFolderIdsInFolderContent

public List<Long> findTestCasesFolderIdsInFolderContent(long folderId)
Specified by:
findTestCasesFolderIdsInFolderContent in interface TestCaseFolderDao

findPairedContentForList

public List<Long[]> findPairedContentForList(List<Long> ids)
Specified by:
findPairedContentForList in interface FolderDao<TestCaseFolder,TestCaseLibraryNode>
Returns:
the list of the node ids which are descendant of the given folder ids paired with their owners

findContentForList

public List<Long> findContentForList(List<Long> ids)
Specified by:
findContentForList in interface FolderDao<TestCaseFolder,TestCaseLibraryNode>
Returns:
the list of the node ids which are descendant of the given folder ids.

findAllFolders

public List<TestCaseFolder> findAllFolders(List<Long> folderIds)
Description copied from interface: FolderDao
will return a (non-null) list of test case folders given their ids

Specified by:
findAllFolders in interface FolderDao<TestCaseFolder,TestCaseLibraryNode>
Returns:


Copyright © 2010-2012 Squashtest TM, Squashtest.org. All Rights Reserved.