nl.surfnet.coin.shared.service
Interface GenericService<T extends DomainObject>

All Known Implementing Classes:
GenericServiceHibernateImpl

public interface GenericService<T extends DomainObject>

Generic service class for CRUD functionality for DomainObject


Method Summary
 org.hibernate.Criteria createCriteria()
           
 void delete(T o)
           
 void detachFromSession(T o)
           
 List<T> findAll()
           
 List<T> findByExample(T exampleInstance)
           
 List<T> findByExample(T exampleInstance, String[] excludes)
           
 T findById(Long id)
          Find by primary key
 int getCount()
           
 Class<T> getPersistentClass()
           
 void saveOrUpdate(Collection<T> coll)
           
 Long saveOrUpdate(T t)
           
 

Method Detail

saveOrUpdate

Long saveOrUpdate(T t)

findById

T findById(Long id)
Find by primary key

Parameters:
id - the entity primary key
Returns:
the domainObject

delete

void delete(T o)

findAll

List<T> findAll()

findByExample

List<T> findByExample(T exampleInstance)

getPersistentClass

Class<T> getPersistentClass()

detachFromSession

void detachFromSession(T o)

getCount

int getCount()

saveOrUpdate

void saveOrUpdate(Collection<T> coll)

createCriteria

org.hibernate.Criteria createCriteria()

findByExample

List<T> findByExample(T exampleInstance,
                      String[] excludes)


Copyright © 2009-2012 SURFnet bv, The Netherlands. All Rights Reserved.