Bertini 2 d882924 (2026-10-06 19:56 UTC)
Numerical algebraic geometry library (C++ core)
Loading...
Searching...
No Matches
bertini::node::NameHolder Class Reference

Capability class for things which have a name. More...

#include <symbol.hpp>

Inheritance diagram for bertini::node::NameHolder:
[legend]

Public Member Functions

const std::string & name () const
void name (const std::string &new_name)
 Set the name.

Protected Member Functions

 ~NameHolder ()=default
 NameHolder ()=default
 NameHolder (std::string new_name)
 Construct holding the given name.

Protected Attributes

std::string name_
 The stored name.

Friends

class boost::serialization::access

Detailed Description

Capability class for things which have a name.

Deliberately NOT a Node: classes that need a name alongside a different primary base (e.g. special_number::Pi, which is a Number) inherit this without creating a diamond in the Node hierarchy.

Mixin holding a name, shared by named nodes without forming a diamond in the hierarchy.

Constructor & Destructor Documentation

◆ ~NameHolder()

bertini::node::NameHolder::~NameHolder ( )
protecteddefault

◆ NameHolder() [1/2]

bertini::node::NameHolder::NameHolder ( )
protecteddefault

◆ NameHolder() [2/2]

bertini::node::NameHolder::NameHolder ( std::string new_name)
inlineexplicitprotected

Construct holding the given name.

Member Function Documentation

◆ name() [1/2]

const std::string & bertini::node::NameHolder::name ( ) const
inline
Returns
The name.

◆ name() [2/2]

void bertini::node::NameHolder::name ( const std::string & new_name)
inline

Set the name.

◆ boost::serialization::access

friend class boost::serialization::access
friend

Member Data Documentation

◆ name_

std::string bertini::node::NameHolder::name_
protected

The stored name.