org.riotfamily.riot.dao.support
Class StaticRiotDao

java.lang.Object
  extended by org.riotfamily.riot.dao.support.RiotDaoAdapter
      extended by org.riotfamily.riot.dao.support.StaticRiotDao
All Implemented Interfaces:
RiotDao

public class StaticRiotDao
extends RiotDaoAdapter

Since:
6.5
Author:
Felix Gnass [fgnass at neteye dot de]

Constructor Summary
StaticRiotDao(List<?> items)
           
 
Method Summary
 Class<?> getEntityClass()
          Returns the class that is accessed by the DAO.
 String getObjectId(Object entity)
          Always returns null.
 Collection<?> list(Object parent, ListParams params)
          Always returns Collections.EMPTY_LIST.
 Object load(String id)
          Always throws an InvalidDataAccessApiUsageException.
 void setEntityClass(Class<?> entityClass)
           
 
Methods inherited from class org.riotfamily.riot.dao.support.RiotDaoAdapter
delete, getListSize, merge, save, update
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

StaticRiotDao

public StaticRiotDao(List<?> items)
Method Detail

setEntityClass

public void setEntityClass(Class<?> entityClass)

getEntityClass

public Class<?> getEntityClass()
Description copied from interface: RiotDao
Returns the class that is accessed by the DAO.

Specified by:
getEntityClass in interface RiotDao
Overrides:
getEntityClass in class RiotDaoAdapter

list

public Collection<?> list(Object parent,
                          ListParams params)
Description copied from class: RiotDaoAdapter
Always returns Collections.EMPTY_LIST.

Specified by:
list in interface RiotDao
Overrides:
list in class RiotDaoAdapter

getObjectId

public String getObjectId(Object entity)
Description copied from class: RiotDaoAdapter
Always returns null.

Specified by:
getObjectId in interface RiotDao
Overrides:
getObjectId in class RiotDaoAdapter

load

public Object load(String id)
            throws DataAccessException
Description copied from class: RiotDaoAdapter
Always throws an InvalidDataAccessApiUsageException.

Specified by:
load in interface RiotDao
Overrides:
load in class RiotDaoAdapter
Throws:
DataAccessException