public interface

ObjectDao

bucket.core.persistence.ObjectDao
Known Indirect Subclasses

Summary

Public Methods
abstract List findAll()
Find all objects currently persisted of a particular type.
abstract List findAllSorted(String sortField)
Find all objects currently persisted of a particular type and sort results by named property.
abstract List findAllSorted(String sortField, boolean cacheable, int offset, int maxResultCount)
Find all objects currently persisted of a particular type and sort results by named property.
abstract Class getPersistentClass()
abstract void refresh(EntityObject objectToRrfresh)
Refreshes the object again with the fresh data from db.
abstract void remove(EntityObject object)
Remove object from persistence.
abstract void replicate(Object objectToReplicate)
Replicate the object.
abstract void save(EntityObject objectToSave)
abstract void saveRaw(EntityObject objectToSave)
saves the object.

Public Methods

public abstract List findAll ()

Find all objects currently persisted of a particular type.

public abstract List findAllSorted (String sortField)

Find all objects currently persisted of a particular type and sort results by named property.

Parameters
sortField the name of the property to be sorted on. This should be null if no sorting is required.

public abstract List findAllSorted (String sortField, boolean cacheable, int offset, int maxResultCount)

Find all objects currently persisted of a particular type and sort results by named property. This version of the method allows more control over the query.

Parameters
sortField the name of the property to be sorted on. This should be null if no sorting is required.
cacheable control whether the results should be cached
offset the index of the first result to be returned
maxResultCount the maximum number of results required. Use -1 to specify no limit.

public abstract Class getPersistentClass ()

public abstract void refresh (EntityObject objectToRrfresh)

Refreshes the object again with the fresh data from db.

public abstract void remove (EntityObject object)

Remove object from persistence.

public abstract void replicate (Object objectToReplicate)

Replicate the object. Replication does not generate a new id if the object does not exist in database and it overwrites the database row if the object already exists in database.

public abstract void save (EntityObject objectToSave)

public abstract void saveRaw (EntityObject objectToSave)

saves the object. if the object is new, this won't set the creation date on the object. if it already exists, then it won't set the date that it was updated.