ClickHouse/base/common/terminalColors.h
Ivan 571d0d541c
Improve CCTZ contrib (#9687)
* common/Types.h → common/types.h
  Also split Core/Defines.h and merge with common/likely.h
* Improve cctz contrib
* Fix ALWAYS_INLINE and unbundled build
* Update Dockerfile from master
* Fix test for unbundled library
2020-03-19 13:38:34 +03:00

16 lines
453 B
C++

#include <string>
#include <common/types.h>
/** Set color in terminal based on 64-bit hash value.
* It can be used to choose some random color deterministically based on some other value.
* Hash value should be uniformly distributed.
*/
std::string setColor(UInt64 hash);
/** Set color for logger priority value. */
const char * setColorForLogPriority(int priority);
/** Undo changes made by the functions above. */
const char * resetColor();