Exemplo n.º 1
0
func (w *WriteBatch) Close() {
	if w.wbatch != nil {
		C.leveldb_writebatch_destroy(w.wbatch)
		w.wbatch = nil
	}

	w.gbatch = nil
}
Exemplo n.º 2
0
// Close releases the underlying memory of a WriteBatch.
func (w *WriteBatch) Close() {
	C.leveldb_writebatch_destroy(w.wbatch)
}
Exemplo n.º 3
0
func (w *WriteBatch) Close() error {
	C.leveldb_writebatch_destroy(w.wbatch)
	w.wbatch = nil

	return nil
}