Method Save
Save(string, ISerializableData, Action, Action<Exception>)
Asynchronously saves data onto the persistence layer. When the async save operation is done, onFinish Action get called.
Declaration
void Save(string identifier, ISerializableData content, Action onSaveCompleted = null, Action<Exception> onSaveFailed = null)
Parameters
| Type | Name | Description |
|---|---|---|
| string | identifier | Identifier of the persistence entry (filename, url, ...) |
| ISerializableData | content | Data to persist (need to be serializable) |
| Action | onSaveCompleted | Called when the saving is completed with success |
| Action<Exception> | onSaveFailed | Called with a detailed exception when the loading failed |