Safe Haskell | None |
---|---|
Language | Haskell98 |
- data LoggingOptions = LoggingOptions {}
- data LogFile
- data LogKind
- defaultLoggingOptions :: LoggingOptions
- data Mode
- data WriteMode
- data ReadMode
- data KCException = KCException {}
- data KCError
- class WithDB db where
- data DB
- close :: WithDB db => db -> IO ()
- type VisitorFull = ByteString -> ByteString -> IO (Either VisitorAction ByteString)
- type VisitorEmpty = ByteString -> IO (Maybe ByteString)
- data VisitorAction
- type Writable = Bool
- accept :: WithDB db => db -> ByteString -> VisitorFull -> VisitorEmpty -> Writable -> IO ()
- acceptBulk :: WithDB db => db -> [ByteString] -> VisitorFull -> VisitorEmpty -> Writable -> IO ()
- iterate :: WithDB db => db -> VisitorFull -> Writable -> IO ()
- scanPara :: WithDB db => db -> VisitorFull -> Int -> IO ()
- set :: WithDB db => db -> ByteString -> ByteString -> IO ()
- setBulk :: WithDB db => db -> [(ByteString, ByteString)] -> Bool -> IO Int64
- add :: WithDB db => db -> ByteString -> ByteString -> IO ()
- replace :: WithDB db => db -> ByteString -> ByteString -> IO ()
- append :: WithDB db => db -> ByteString -> ByteString -> IO ()
- get :: WithDB db => db -> ByteString -> IO (Maybe ByteString)
- getBulk :: WithDB db => db -> [ByteString] -> Bool -> IO [(ByteString, ByteString)]
- remove :: WithDB db => db -> ByteString -> IO ()
- removeBulk :: WithDB db => db -> [ByteString] -> Bool -> IO Int64
- seize :: WithDB db => db -> ByteString -> IO (Maybe ByteString)
- clear :: WithDB db => db -> IO ()
- copy :: WithDB db => db -> FilePath -> IO ()
- dump :: WithDB db => db -> FilePath -> IO ()
- load :: WithDB db => db -> FilePath -> IO ()
- count :: WithDB db => db -> IO Int64
- size :: WithDB db => db -> IO Int64
- path :: WithDB db => db -> IO String
- status :: WithDB db => db -> IO String
- data MergeMode
- data GenericDB = WithDB db => GenericDB db
- merge :: WithDB db => db -> [GenericDB] -> MergeMode -> IO ()
- data Cursor
- cursor :: WithDB db => db -> IO Cursor
- curAccept :: Cursor -> VisitorFull -> Bool -> Bool -> IO ()
- curSetValue :: Cursor -> ByteString -> Bool -> IO ()
- curGetKey :: Cursor -> Bool -> IO ByteString
- curGetValue :: Cursor -> Bool -> IO ByteString
- curGet :: Cursor -> Bool -> IO (ByteString, ByteString)
- curRemove :: Cursor -> IO ()
- curSeize :: Cursor -> IO (ByteString, ByteString)
- curJump :: Cursor -> IO ()
- curJumpKey :: Cursor -> ByteString -> IO ()
- curJumpBack :: Cursor -> IO ()
- curJumpBackKey :: Cursor -> ByteString -> IO ()
- curStep :: Cursor -> IO ()
- curStepBack :: Cursor -> IO ()
Logging options
data LoggingOptions Source #
defaultLoggingOptions :: LoggingOptions Source #
Default logging options, outputting to stdout, all messages, and no prefix.
Opening mode
Exceptions
Type class
Operations
Closing
Visitor
type VisitorFull Source #
= ByteString | Key |
-> ByteString | Value |
-> IO (Either VisitorAction ByteString) | If a |
type VisitorEmpty Source #
= ByteString | |
-> IO (Maybe ByteString) | If the |
data VisitorAction Source #
NoOperation | Don't do anything |
Remove | Remove the record |
accept :: WithDB db => db -> ByteString -> VisitorFull -> VisitorEmpty -> Writable -> IO () Source #
Executes the VisitorFull
on the existent records, and VisitorEmpty
on the missing ones.
acceptBulk :: WithDB db => db -> [ByteString] -> VisitorFull -> VisitorEmpty -> Writable -> IO () Source #
Setting
set :: WithDB db => db -> ByteString -> ByteString -> IO () Source #
setBulk :: WithDB db => db -> [(ByteString, ByteString)] -> Bool -> IO Int64 Source #
add :: WithDB db => db -> ByteString -> ByteString -> IO () Source #
replace :: WithDB db => db -> ByteString -> ByteString -> IO () Source #
append :: WithDB db => db -> ByteString -> ByteString -> IO () Source #
Getting
get :: WithDB db => db -> ByteString -> IO (Maybe ByteString) Source #
getBulk :: WithDB db => db -> [ByteString] -> Bool -> IO [(ByteString, ByteString)] Source #
Remove
removeBulk :: WithDB db => db -> [ByteString] -> Bool -> IO Int64 Source #
seize :: WithDB db => db -> ByteString -> IO (Maybe ByteString) Source #
Retrieve the value of a record and remove it atomically
Copying/Backup
Info and statistics
Merging
Cursors
Creation
Visitor
Setting
curSetValue :: Cursor -> ByteString -> Bool -> IO () Source #
Getting
curGetValue :: Cursor -> Bool -> IO ByteString Source #
curGet :: Cursor -> Bool -> IO (ByteString, ByteString) Source #
Removing
curSeize :: Cursor -> IO (ByteString, ByteString) Source #
Moving
curJumpKey :: Cursor -> ByteString -> IO () Source #
curJumpBack :: Cursor -> IO () Source #
curJumpBackKey :: Cursor -> ByteString -> IO () Source #
curStepBack :: Cursor -> IO () Source #