org.globus.wsrf
Interface PersistenceCallback

All Known Subinterfaces:
PersistentResource
All Known Implementing Classes:
EnumResource, PersistentReflectionResource, PersistentSubscription, TransientEnumResource

public interface PersistenceCallback

Defines callback operations for persistence operations. These operations will be invoked when used with ResourceHomeImpl. Currently, the ResourceHomeImpl will only invoke the load() function automatically. The resource implementation itself is responsible for calling store() function to synchronize its state on disk.


Method Summary
 void load(ResourceKey key)
          Loads the resource state.
 void store()
          Saves the resource state.
 

Method Detail

load

void load(ResourceKey key)
          throws ResourceException,
                 NoSuchResourceException,
                 InvalidResourceKeyException
Loads the resource state.

Throws:
NoSuchResourceException - if no resource state exists for the specified key.
InvalidResourceKeyException - if the resource key is invalid.
ResourceException - if the load operation fails for any other reason.

store

void store()
           throws ResourceException
Saves the resource state.

Throws:
ResourceException - if the store operation fails.