Skip to content

Commit

Permalink
tidy Example code
Browse files Browse the repository at this point in the history
  • Loading branch information
octu0 committed Jul 19, 2022
1 parent c55bf40 commit ff1f45d
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,10 +53,10 @@ func main() {
// Put() can be specify io.Reader
db.Put([]byte("foo"), bytes.NewReader([]byte("very large data...")))

// PutWithTTL/PutBytesWithTTL can be set to data with expiration time
// PutWithTTL()/PutBytesWithTTL() can be set to data with expiration time
db.PutWithTTL([]byte("bar"), bytes.NewReader(data), 10*time.Second)

// flushes all buffers to disk
// Sync() flushes all buffers to disk
db.Sync()

r, err := db.Get([]byte("foo"))
Expand All @@ -71,7 +71,7 @@ func main() {
// Delete() can delete data with key
db.Delete([]byte("foo"))

// deletes all expired keys
// RunGC() deletes all expired keys
db.RunGC()

// Merge() rebuilds databases and reclaims disk space
Expand Down

0 comments on commit ff1f45d

Please sign in to comment.