CatapultServer  v0.5.0.1 (Elephant)
NodeRoles.h
Go to the documentation of this file.
1 
21 #pragma once
23 #include <string>
24 
25 namespace catapult { namespace ionet {
26 
28  enum class NodeRoles : uint32_t {
30  None,
31 
33  Peer = 0x01,
34 
36  Api = 0x02
37  };
38 
40 
41 
42  bool TryParseValue(const std::string& str, NodeRoles& roles);
43 }}
catapult::ionet::NodeRoles::Peer
A peer node.
MAKE_BITWISE_ENUM
#define MAKE_BITWISE_ENUM(ENUM_TYPE)
Defines bitwise helpers for ENUM_TYPE.
Definition: BitwiseEnum.h:25
NodeRoles.h
BitwiseEnum.h
catapult::ionet::NodeRoles::None
No roles.
catapult::ionet::NodeRoles
NodeRoles
A node's role.
Definition: NodeRoles.h:28
catapult::utils::TryParseBitwiseEnumValue
bool TryParseBitwiseEnumValue(const std::array< std::pair< const char *, T >, N > &stringToValueMapping, const std::string &str, T &parsedValues)
Tries to parse str into a bitwise enum value (parsedValue) given a mapping of strings to values (stri...
Definition: ConfigurationValueParsers.h:118
catapult::ionet::NodeRoles::Api
An api node.
ConfigurationValueParsers.h
catapult
Definition: AddressExtractionExtension.cpp:28
catapult::ionet::TryParseValue
bool TryParseValue(const std::string &str, ConnectionSecurityMode &modes)
Tries to parse str into connection security modes.
Definition: IoEnums.cpp:72