Class StructuredStoreGameSaveAdapter
IGameSaveStore implementation that translates load/save/delete/query into calls
against the generic IStructuredStore contract, via GameSaveRecordMapping.
The single adapter every game-save backend (key-value, HTTP, and any future
Postgres/MySql/Mongo/Sqlite provider) shares.
Inheritance
StructuredStoreGameSaveAdapter
Assembly: Serenity.GameSave.Infrastructure.dll
Syntax
public class StructuredStoreGameSaveAdapter : IGameSaveStore
Constructors
StructuredStoreGameSaveAdapter(IStructuredStore, StoreTable, ILogService)
Declaration
public StructuredStoreGameSaveAdapter(IStructuredStore store, StoreTable table, ILogService logService)
Parameters
| Type |
Name |
Description |
| IStructuredStore |
store |
The generic structured store backing every game-save operation.
|
| StoreTable |
table |
The table/collection game saves are stored in.
|
| ILogService |
logService |
Logging service used to report failures. May be null.
|
Methods
DeleteAsync(SaveSlotId, CancellationToken)
Declaration
public Task DeleteAsync(SaveSlotId slotId, CancellationToken cancellationToken)
Parameters
Returns
ExistsAsync(SaveSlotId, CancellationToken)
Declaration
public Task<bool> ExistsAsync(SaveSlotId slotId, CancellationToken cancellationToken)
Parameters
Returns
GetSlotSummaryAsync(SaveSlotId, CancellationToken)
Declaration
public Task<SaveSlotSummary> GetSlotSummaryAsync(SaveSlotId slotId, CancellationToken cancellationToken)
Parameters
Returns
HealthCheckAsync(CancellationToken)
Declaration
public Task<bool> HealthCheckAsync(CancellationToken cancellationToken)
Parameters
Returns
LoadAsync(SaveSlotId, CancellationToken)
Declaration
public Task<SaveDocument> LoadAsync(SaveSlotId slotId, CancellationToken cancellationToken)
Parameters
Returns
QuerySummariesAsync(CancellationToken)
Declaration
public Task<IReadOnlyList<SaveSlotSummary>> QuerySummariesAsync(CancellationToken cancellationToken)
Parameters
Returns
SaveAsync(SaveSlotId, SaveDocument, CancellationToken)
Declaration
public Task SaveAsync(SaveSlotId slotId, SaveDocument document, CancellationToken cancellationToken)
Parameters
Returns
Implements