Package dev.getelements.elements.rt
Interface PersistenceStrategy
- All Known Implementing Classes:
TransactionPersistenceStrategy
public interface PersistenceStrategy
Provides a means to a persist the state of
Resource instances as managed by an associated
ResourceService.-
Method Summary
Modifier and TypeMethodDescriptionstatic PersistenceStrategyGets a nullPersistenceStrategywhich is designed to work withResourceServicetypes which do not support persistence at all.voidpersist(ResourceId resourceId) Requests that theResourceIdwith the suppliedResourceIdbe persisted.
-
Method Details
-
persist
Requests that theResourceIdwith the suppliedResourceIdbe persisted. Throwing an exception if the operation is not possible at the time being.- Parameters:
resourceId- theResourceIdto persist
-
getNullPersistence
Gets a nullPersistenceStrategywhich is designed to work withResourceServicetypes which do not support persistence at all.- Returns:
-