01: /*--------------------------------------------------------------------------*
02: | Copyright (C) 2006 Christopher Kohlhaas |
03: | |
04: | This program is free software; you can redistribute it and/or modify |
05: | it under the terms of the GNU General Public License as published by the |
06: | Free Software Foundation. A copy of the license has been included with |
07: | these distribution in the COPYING file, if not go to www.fsf.org |
08: | |
09: | As a special exception, you are granted the permissions to link this |
10: | program with every library, which license fulfills the Open Source |
11: | Definition as published by the Open Source Initiative (OSI). |
12: *--------------------------------------------------------------------------*/
13: /** A StorageOperator that operates on a LocalCache-Object.
14: */package org.rapla.storage;
15:
16: import java.util.Collection;
17:
18: import org.rapla.entities.EntityNotFoundException;
19: import org.rapla.entities.storage.EntityResolver;
20: import org.rapla.entities.storage.RefEntity;
21: import org.rapla.framework.RaplaException;
22:
23: public interface CachableStorageOperator extends StorageOperator {
24: String ROLE = CachableStorageOperator.class.getName();
25:
26: LocalCache getCache();
27:
28: void dispatch(UpdateEvent evt) throws RaplaException;
29:
30: void authenticate(String username, String password)
31: throws RaplaException;
32:
33: void setCache(LocalCache cache) throws RaplaException;
34:
35: void saveData() throws RaplaException;
36:
37: RefEntity resolveId(Object id) throws EntityNotFoundException;
38:
39: EntityResolver createEntityResolver(Collection entities,
40: LocalCache parent);
41: }
|