gate.util.persistence
Interface Persistence

All Superinterfaces:
Serializable
All Known Implementing Classes:
AnalyserRunningStrategyPersistence, CollectionPersistence, ConditionalControllerPersistence, ConditionalSerialAnalyserControllerPersistence, ControllerPersistence, CorpusPersistence, DSPersistence, LanguageAnalyserPersistence, LRPersistence, MapPersistence, PersistenceManager.SlashDevSlashNull, PersistenceManager.URLHolder, PRPersistence, SerialAnalyserControllerPersistence, UnconditionalRunningStrategyPersistence

public interface Persistence
extends Serializable

Defines an object that holds persistent data about another object. Storing an arbitrary object will consist of creating an appropiate Persistence object for it and storing that one (via serialisation). Restoring a previously saved object will consist of restoring the persistence object and using the data it stores to create a new object that is as similar as possible to the original object.


Method Summary
 Object createObject()
          Creates a new object from the data contained.
 void extractDataFromSource(Object source)
          Populates this Persistence with the data that needs to be stored from the original source object.
 

Method Detail

extractDataFromSource

void extractDataFromSource(Object source)
                           throws PersistenceException
Populates this Persistence with the data that needs to be stored from the original source object.

Throws:
PersistenceException

createObject

Object createObject()
                    throws PersistenceException,
                           ResourceInstantiationException
Creates a new object from the data contained. This new object is supposed to be a copy for the original object used as source for data extraction.

Throws:
PersistenceException
ResourceInstantiationException