scram::mef::NamedBranch
Named branches that can be referenced and reused.
#include <event_tree.h>
Inherits from scram::mef::Element, scram::mef::Branch, scram::mef::NodeMark, scram::mef::Usage, scram::mef::ContainerElement, boost::noncopyable
Public Functions
| Name | |
|---|---|
| Element(std::string name)<br>Constructs an element with an original name. |
Public Attributes
| Name | |
|---|---|
| constexpr const char * | kTypeString <br>For error message. |
Additional inherited members
Public Types inherited from scram::mef::Element
| Name | |
|---|---|
| using ext::linear_set< Attribute, AttributeKey > | AttributeMap <br>Unique attribute map keyed with the attribute names. |
Public Functions inherited from scram::mef::Element
| Name | |
|---|---|
| const std::string & | name() const |
| std::string_view | name_view() const |
| const std::string & | label() const |
| void | label(std::string label)<br>Sets the element label. |
| const AttributeMap & | attributes() const |
| void | AddAttribute(Attribute attr)<br>Adds an attribute to the attribute map of this element. |
| void | SetAttribute(Attribute attr)<br>Sets an attribute to the attribute map. |
| const Attribute * | GetAttribute(std::string_view name) const |
| std::optional< Attribute > | RemoveAttribute(std::string_view name)<br>Removes an attribute of this element. |
Protected Functions inherited from scram::mef::Element
| Name | |
|---|---|
| ~Element() =default | |
| void | name(std::string name)<br>Resets the element name. |
Public Types inherited from scram::mef::Branch
| Name | |
|---|---|
| using std::variant< Sequence *, Fork *, NamedBranch * > | Target <br>The types of possible branch end-points. |
Public Functions inherited from scram::mef::Branch
| Name | |
|---|---|
| void | instructions(std::vector< Instruction * > instructions)<br>Sets the instructions to execute at the branch. |
| const std::vector< Instruction * > & | instructions() const |
| void | target(Target target)<br>Sets the target for the branch. |
| const Target & | target() const |
Public Types inherited from scram::mef::NodeMark
| Name | |
|---|---|
| enum std::uint8_t | Mark { kClear, kTemporary, kPermanent}<br>Possible marks for the node. |
Public Functions inherited from scram::mef::NodeMark
| Name | |
|---|---|
| Mark | mark() const |
| void | mark(Mark label)<br>Sets the mark for this node. |
Protected Functions inherited from scram::mef::NodeMark
| Name | |
|---|---|
| ~NodeMark() =default |
Public Functions inherited from scram::mef::Usage
| Name | |
|---|---|
| bool | usage() const |
| void | usage(bool usage) |
Protected Functions inherited from scram::mef::Usage
| Name | |
|---|---|
| ~Usage() =default |
Protected Functions inherited from scram::mef::ContainerElement
| Name | |
|---|---|
| const Element * | container() const |
Friends inherited from scram::mef::ContainerElement
| Name | |
|---|---|
| class | Container |
Public Functions Documentation
function Element
explicit Element(
std::string name
)Constructs an element with an original name.
Parameters:
- name The local identifier name.
Exceptions:
- LogicError The name is required and empty.
- ValidityError The name is malformed.
The name is expected to conform to identifier requirements described in the MEF documentation and additions.
Public Attributes Documentation
variable kTypeString
static constexpr const char * kTypeString = "branch";For error message.
Updated on 2025-11-11 at 16:51:08 +0000
