rocksutil is a ToolKit for C++ developer,It has a lot of useful tools to make coding more faster and easier. It supports LINUX and MACOS platforms
Easy way to operate files, directories, threads, times, etc
Here is an EXAMPLE
Find more usages Here
Files & Directories |
---|
Env::NewDirectory |
Env::FileExists |
Env::GetChildren |
Env::GetChildrenFileAttributes |
Env::DeleteFile |
Env::CreateDir |
Env::CreateDirIfMissing |
Env::GetFileSize |
Env::GetFileModificationTime |
Env::RenameFile |
Env::LinkFile |
Env::LockFile |
Env::UnlockFile |
Env::GetAbsolutePath |
Thread & ThreadPool |
---|
Env::Schedule |
Env::UnSchedule |
Env::StartThread |
Env::WaitForJoin |
Env::GetThreadPoolQueueLen |
Env::SetBackgroundThreads |
Env::IncBackgroundThreadsIfNeeded |
Env::LowerThreadPoolIOPriority |
Env::GetThreadID |
Time & System |
---|
Env::NowMicros |
Env::NowNanos |
Env::SleepForMicroseconds |
Env::GetHostName |
Env::GetCurrentTime |
Easy way to use Log
Here is an EXAMPLE
Easy way to use thread-specific data
Here is an EXAMPLE
Easy way to use Lock, RWLock, SpinLock
Here is an EXAMPLE
Easy way to use lru cache
Here is an EXAMPLE
Easy way to read & write file in random or sequential mode, and use EnvOptions to manipulate the writer & reader to use [mmap, direct_io, buffer_read_write...]
Here is an EXAMPLE
Easy way to write or recover from a robust format wal, based on FileWriter & FileReader
Here is an EXAMPLE
Find more info in
This ToolKit is mainly extracted from rocksdb, I remove some specific features, change some and make it more UNIVERSAL