GNDMS 0.6.0
RESTful verison of GNDMS
Public Member Functions | Protected Member Functions | Private Attributes

de.zib.gndms.model.common.repository.QueuedTransientDao< K, M, D > Class Reference

Inheritance diagram for de.zib.gndms.model.common.repository.QueuedTransientDao< K, M, D >:
de.zib.gndms.model.common.repository.QueuedDao< K, M, D > de.zib.gndms.model.common.repository.Dao< K, M, D >

List of all members.

Public Member Functions

void deleteByKey (K key)
 Deletes a model matching the given key.
void delete (M model)
 Deletes model from the repo.
void add (M model, K key)
 Addes a model to the dao.

Protected Member Functions

abstract M newModel (K key)
 Delegated to Transient Dao;.
provideGet (K key)
 This should return new models or delegate calls to underlying daos.
void setDao (Dao< K, M, D > dao)

Private Attributes

Dao< K, M, D > dao

Detailed Description

Author:
try ma ik jo rr a zib
Version:
$Id$

Date: 05.01.2011, Time: 15:35:13


Member Function Documentation

void de.zib.gndms.model.common.repository.QueuedTransientDao< K, M, D >.add ( model,
key 
)

Addes a model to the dao.

Parameters:
modelThe model to add, with the key to use.

Implements de.zib.gndms.model.common.repository.Dao< K, M, D >.

                                      {
        dao.add( model, key );
    }
void de.zib.gndms.model.common.repository.QueuedTransientDao< K, M, D >.delete ( model)

Deletes model from the repo.

Parameters:
modelThe model to delete.
Note:
M must implement equals.

Implements de.zib.gndms.model.common.repository.Dao< K, M, D >.

                                  {
        dao.delete( model );
    }
void de.zib.gndms.model.common.repository.QueuedTransientDao< K, M, D >.deleteByKey ( key)

Deletes a model matching the given key.

Parameters:
keyThe key.

NOTE: Stupid type erasure.

Implements de.zib.gndms.model.common.repository.Dao< K, M, D >.

                                     {
        dao.deleteByKey( key );
    }
M de.zib.gndms.model.common.repository.QueuedTransientDao< K, M, D >.provideGet ( key) [protected, virtual]

This should return new models or delegate calls to underlying daos.

Parameters:
keyModel key if required for construction.
Returns:
A new model.

Note: when this method is called the model is allready inserted into the queue.

Implements de.zib.gndms.model.common.repository.QueuedDao< K, M, D >.

                                    {
        return dao.get( key );
    }

Member Data Documentation

Dao<K,M,D> de.zib.gndms.model.common.repository.QueuedTransientDao< K, M, D >.dao [private]
Initial value:
 new TransientDao<K,M,D> () {
        protected M newModel( K key ) {
            return QueuedTransientDao.this.newModel( key );
        }

        public K create() {
            return QueuedTransientDao.this.create();
        }
    }

The documentation for this class was generated from the following file:
 All Classes Namespaces Functions Variables