1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16 package mnemosyne.archiver;
17
18 import mnemosyne.core.PersistentRoot;
19 import mnemosyne.core.Transaction;
20 import org.apache.commons.logging.Log;
21 import org.apache.commons.logging.LogFactory;
22
23 /***
24 * An implementation of the archiver that does not persist to durable storage.
25 * This might be useful for demos, testing, or an in memory cache that requires
26 * ACID properties.
27 *
28 * @version $Id: TransientArchiver.java,v 1.1.1.1 2004/08/07 06:40:55 charlesblaxland Exp $
29 */
30 public class TransientArchiver implements Archiver
31 {
32 private static final Log log = LogFactory.getLog(TransientArchiver.class);
33
34 public PersistentRoot loadLatest() throws ArchiverException
35 {
36 log.info("Persistent root reloaded");
37 return null;
38 }
39
40 public void saveSnapshot(PersistentRoot root) throws ArchiverException
41 {
42 log.info("Snapshot saved");
43 }
44
45 public void saveTransaction(Transaction transaction) throws ArchiverException
46 {
47 log.info("Transaction saved");
48 }
49 }