private void ResetBatch() { _writeBatch = new WriteBatch(); _levelDbSnapshot?.Dispose(); _levelDbSnapshot = _db.GetSnapshot(); ReadOptions dbOptions = new ReadOptions { FillCache = false, Snapshot = _levelDbSnapshot }; _balances = new DbCache <Nep5BalanceKey, Nep5Balance>(_db, dbOptions, _writeBatch, Nep5BalancePrefix); if (_shouldTrackHistory) { _transfersSent = new DbCache <Nep5TransferKey, Nep5Transfer>(_db, dbOptions, _writeBatch, Nep5TransferSentPrefix); _transfersReceived = new DbCache <Nep5TransferKey, Nep5Transfer>(_db, dbOptions, _writeBatch, Nep5TransferReceivedPrefix); } }
public override void Dispose() { snapshot.Dispose(); }
public void Dispose() { snapshot.Dispose(); }