org.pandora.knowledge.serialized
Class SerializedMemory

java.lang.Object
  extended by org.pandora.knowledge.BasicMemory
      extended by org.pandora.knowledge.serialized.SerializedMemory
All Implemented Interfaces:
Memory

public class SerializedMemory
extends BasicMemory

Defines a set of networks that make up a knowledge base. Defines long term, short term and flash networks. Basic implementation using serialization for persistence.


Field Summary
static java.lang.String knowledgeBaseFileName
           
 
Constructor Summary
SerializedMemory()
           
 
Method Summary
 void restore()
          This implementation does not support persistence.
 void save()
          Merge the short term memory into the long term and clears the short term.
 
Methods inherited from class org.pandora.knowledge.BasicMemory
abort, addActiveMemory, addListener, createMemory, deleteMemory, destroyMemory, getActiveMemory, getListeners, getLongTermMemory, getMemoryName, getPandora, getShortTermMemory, importMemory, initialize, newMemory, restore, setActiveMemory, setLongTermMemory, setPandora, setShortTermMemory, shutdown, switchMemory, toString
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

knowledgeBaseFileName

public static java.lang.String knowledgeBaseFileName
Constructor Detail

SerializedMemory

public SerializedMemory()
Method Detail

save

public void save()
          throws MemoryStorageException
Description copied from class: BasicMemory
Merge the short term memory into the long term and clears the short term. This is similar to a transactional commit. The changes should also be persisted, as the long term should always just be a cache of the storage. This implementation does not support persistence.

Specified by:
save in interface Memory
Overrides:
save in class BasicMemory
Throws:
MemoryStorageException

restore

public void restore()
             throws MemoryStorageException
Description copied from class: BasicMemory
This implementation does not support persistence.

Specified by:
restore in interface Memory
Overrides:
restore in class BasicMemory
Throws:
MemoryStorageException