Class SnapshotStore
- Namespace
- InSite.Persistence
- Assembly
- InSite.Persistence.dll
public class SnapshotStore : ISnapshotStore
- Inheritance
-
SnapshotStore
- Implements
- Inherited Members
Constructors
SnapshotStore(string, string)
public SnapshotStore(string databaseConnectionString, string offlineStorageFolder)
Parameters
Methods
Box(Guid)
Copies a snapshot to offline storage and removes it from online logs.
public void Box(Guid aggregate)
Parameters
aggregateGuid
Count(Guid)
Counts the number of snapshots in the store for an aggregate.
public int Count(Guid id)
Parameters
idGuid
Returns
Delete(Guid, string)
Deletes a snapshot from the store.
public void Delete(Guid aggregate, string type)
Parameters
Get(Guid)
Gets a snapshot from the store.
public Snapshot Get(Guid id)
Parameters
idGuid
Returns
Save(Snapshot)
Saves a snapshot to the store.
public void Save(Snapshot snapshot)
Parameters
snapshotSnapshot
Unbox(Guid)
Retrieves an aggregate from offline storage and returns only its most recent state.
public Snapshot Unbox(Guid aggregate)
Parameters
aggregateGuid