public interface PersistenceCallback
| Modifier and Type | Method and Description |
|---|---|
Map<String,String> |
onLoadData()
Loads persisted data from storage.
|
boolean |
onSaveData(Map<String,String> toSave,
Set<String> toDelete) |
boolean onSaveData(Map<String,String> toSave, Set<String> toDelete)
toSave - A list of new or modified data which must be saved. The key is safe
for filename and any other system sensitive to special characters. The value must be saved.toDelete - A list of data which must be deleted. For this method to return true, each item in this collection must not
exist by the time this method completes.true if the data were correctly saved and deleted, otherwise false@Nonnull Map<String,String> onLoadData()
DataStorage.restore() is called. Will be invoked on the same
thread.