CatapultServer  v0.5.0.1 (Elephant)
EntityType.h File Reference
Include dependency graph for EntityType.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Namespaces

 catapult
 
 catapult::model
 

Macros

#define DEFINE_ENTITY_TYPE(BASIC_TYPE, FACILITY, DESCRIPTION, CODE)
 Defines entity type given BASIC_TYPE, FACILITY, DESCRIPTION and CODE. More...
 
#define DEFINE_TRANSACTION_TYPE(FACILITY, DESCRIPTION, CODE)   DEFINE_ENTITY_TYPE(Transaction, FACILITY, DESCRIPTION, CODE)
 Defines transaction type given FACILITY, DESCRIPTION and CODE. More...
 

Enumerations

enum  catapult::model::BasicEntityType : uint8_t { catapult::model::BasicEntityType::Other = 0x0, catapult::model::BasicEntityType::Transaction = 0x1, catapult::model::BasicEntityType::Block = 0x2 }
 
enum  catapult::model::EntityType : uint16_t
 Enumeration of entity types. More...
 

Functions

constexpr EntityType catapult::model::MakeEntityType (BasicEntityType basicEntityType, FacilityCode facilityCode, uint8_t code)
 Makes entity type given basicEntityType, facilityCode and code. More...
 
 catapult::model::DEFINE_ENTITY_TYPE (Block, Core, Nemesis_Block, 0)
 Nemesis block. More...
 
 catapult::model::DEFINE_ENTITY_TYPE (Block, Core, Block, 1)
 Block. More...
 
constexpr BasicEntityType catapult::model::ToBasicEntityType (EntityType type)
 Converts an entity type into a basic entity type. More...
 
std::ostream & catapult::model::operator<< (std::ostream &out, EntityType entityType)
 Insertion operator for outputting entityType to out. More...
 

Macro Definition Documentation

◆ DEFINE_ENTITY_TYPE

#define DEFINE_ENTITY_TYPE (   BASIC_TYPE,
  FACILITY,
  DESCRIPTION,
  CODE 
)
Value:
constexpr auto Entity_Type_##DESCRIPTION = model::MakeEntityType( \
(model::BasicEntityType::BASIC_TYPE), \
(model::FacilityCode::FACILITY), \
CODE)

Defines entity type given BASIC_TYPE, FACILITY, DESCRIPTION and CODE.

◆ DEFINE_TRANSACTION_TYPE

#define DEFINE_TRANSACTION_TYPE (   FACILITY,
  DESCRIPTION,
  CODE 
)    DEFINE_ENTITY_TYPE(Transaction, FACILITY, DESCRIPTION, CODE)

Defines transaction type given FACILITY, DESCRIPTION and CODE.

catapult::model::MakeEntityType
constexpr EntityType MakeEntityType(BasicEntityType basicEntityType, FacilityCode facilityCode, uint8_t code)
Makes entity type given basicEntityType, facilityCode and code.
Definition: EntityType.h:46