org.shredzone.repowatch.repository.hib
Class RepositoryDAOHibImpl

java.lang.Object
  extended by org.shredzone.repowatch.repository.hib.BaseDAOHibImpl<Repository>
      extended by org.shredzone.repowatch.repository.hib.RepositoryDAOHibImpl
All Implemented Interfaces:
BaseDAO<Repository>, RepositoryDAO

@Repository
@Transactional
public class RepositoryDAOHibImpl
extends BaseDAOHibImpl<Repository>
implements RepositoryDAO

A Hibernate implementation of RepositoryDAO.

Version:
$Revision: 328 $

Constructor Summary
RepositoryDAOHibImpl()
           
 
Method Summary
 Repository fetch(long id)
          Fetches the entity with the given ID.
 List<Repository> findAllRepositories()
          Returns a list of all repositories.
 List<Repository> findRepositories(Domain domain)
          Returns a list of all repositories for the given Domain.
 Repository findRepository(Domain domain, String name, String architecture)
          Finds a repository in the Domain with the given name and architecture.
 
Methods inherited from class org.shredzone.repowatch.repository.hib.BaseDAOHibImpl
delete, getCurrentSession, insert, merge
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.shredzone.repowatch.repository.BaseDAO
delete, insert, merge
 

Constructor Detail

RepositoryDAOHibImpl

public RepositoryDAOHibImpl()
Method Detail

fetch

@Transactional(readOnly=true)
public Repository fetch(long id)
Description copied from interface: BaseDAO
Fetches the entity with the given ID.

Specified by:
fetch in interface BaseDAO<Repository>
Parameters:
id - Entity ID
Returns:
Entity

findRepository

@Transactional(readOnly=true)
public Repository findRepository(Domain domain,
                                               String name,
                                               String architecture)
Description copied from interface: RepositoryDAO
Finds a repository in the Domain with the given name and architecture.

Specified by:
findRepository in interface RepositoryDAO
Parameters:
domain - Domain to search for the repository.
name - Name of the repository (e.g. "updates")
architecture - Architecture string (e.g. "i386")
Returns:
The Repository that was found, or null if there was none.

findAllRepositories

public List<Repository> findAllRepositories()
Description copied from interface: RepositoryDAO
Returns a list of all repositories.

Specified by:
findAllRepositories in interface RepositoryDAO
Returns:
List of all Repository entities.

findRepositories

public List<Repository> findRepositories(Domain domain)
Description copied from interface: RepositoryDAO
Returns a list of all repositories for the given Domain.

Specified by:
findRepositories in interface RepositoryDAO
Parameters:
domain - Domain to find all Repository for
Returns:
List of all Repository entities for that Domain.


Copyright © 2007-2011 shredzone.org. All Rights Reserved.