8 Commits

Author SHA1 Message Date
Jae Kwon
4ce8448d7f
Nil keys are OK, deprecate BeginningKey/EndingKey (#101)
* Nil keys are OK, deprecate BeginningKey/EndingKey
2017-12-17 13:11:28 -08:00
Emmanuel Odeke
a7b20d4e46
db: Simplify exists check, fix IsKeyInDomain signature, Iterator Close
+ *FSDB.HasKey now uses common.FileExists to test for file existence
+ IsKeyInDomain takes key as a []byte slice instead of as a string
to avoid extraneous []byte<-->string conversions for start and end
+ Iterator.Close() instead of Iterator.Release()
+ withDB helper to encapsulate DB creation, deferred cleanups
so that for loops can use opened DBs and discard them ASAP

Addressing accepted changes from review with @jaekwon
2017-12-15 02:58:51 -07:00
Jae Kwon
5636a02d03 Remove GetError() from Iterator 2017-12-12 19:19:26 -08:00
Ethan Buchman
5b7f90dfb2 db: test panic on nil key 2017-12-12 18:42:47 -05:00
Ethan Buchman
781f6c5d22 db: some comments in types.go 2017-12-12 18:04:05 -05:00
Jae Kwon
7f650cea86 Remove Prev from Iterator 2017-12-12 14:45:31 -08:00
Jae Kwon
0d03cd9e31 Make it compile 2017-12-12 14:00:03 -08:00
Jae Kwon
50a30aafc1 New canonical Iterator 2017-12-12 12:44:47 -08:00