Interface ISaveLoader
- Namespace
- Aarthificial.Safekeeper.Loaders
- Assembly
- Aarthificial.Safekeeper.dll
A common interface for saving and loading data in the persistent storage.
public interface ISaveLoader
Methods
Create()
Create the save data for this save.
Task<ISaveData> Create()
Returns
Remarks
This method is used if the save does not exist yet. It should not save the data to the persistent storage, only create it. This data will later be passed to Save(ISaveData).
Delete()
Remove this save from the persistent storage.
Task Delete()
Returns
Exists()
Check if the save has already been created.
Task<bool> Exists()
Returns
GetName()
Get the name of this save.
Task<string> GetName()
Returns
Remarks
Used exclusively for debugging purposes.
Load()
Load the data from the persistent storage.
Task<ISaveData> Load()
Returns
Save(ISaveData)
Save the data to the persistent storage.
Task Save(ISaveData data)
Parameters
data
ISaveDataThe data to save.