public void Commit() { foreach (var item in cache) { switch (item.Value.State) { case TrackState.Added: case TrackState.Changed: store.Put(Key(item.Key), item.Value.Node.ToArray()); break; case TrackState.Deleted: store.Delete(Key(item.Key)); break; } } cache.Clear(); }
protected override void DeleteInternal(StorageKey key) { snapshot?.Delete(key.ToArray()); }
protected override void DeleteInternal(TKey key) { snapshot?.Delete(prefix, key.ToArray()); }