Symmetri
Loading...
Searching...
No Matches
colors.hpp File Reference
#include <string.h>
#include <array>
#include <cassert>
#include <cstdint>
#include <limits>
#include <string_view>
#include <vector>

Go to the source code of this file.

Classes

class  symmetri::Token
 Tokens are elements that can reside in places. Tokens can have a color which makes them distinguishable from other tokens. Tokens that have the same color are not distinguishable. Users can create their own token-colors by either using the CREATE_CUSTOM_TOKEN-macro (compile-time) or by calling Token's public constructor which takes a token-name. More...
struct  std::hash< symmetri::Token >
struct  symmetri::Scheduled
struct  symmetri::Started
struct  symmetri::Success
struct  symmetri::Deadlocked
struct  symmetri::Canceled
struct  symmetri::Paused
struct  symmetri::Failed
struct  symmetri::Cancel

Macros

#define CREATE_CUSTOM_TOKEN(name)
 A macro from which we can create token-colors. Colors ceated this way end up in the symmetri namespace.

Variables

static Scheduled symmetri::Scheduled
static Started symmetri::Started
static Success symmetri::Success
static Deadlocked symmetri::Deadlocked
static Canceled symmetri::Canceled
static Paused symmetri::Paused
static Failed symmetri::Failed
static Cancel symmetri::Cancel

Macro Definition Documentation

◆ CREATE_CUSTOM_TOKEN

#define CREATE_CUSTOM_TOKEN ( name)
Value:
namespace symmetri { \
struct name : public Token { \
constexpr name() : Token(sym_impl::type_name<name>().data()) {} \
}; \
static inline name name; \
}

A macro from which we can create token-colors. Colors ceated this way end up in the symmetri namespace.