cgv
Loading...
Searching...
No Matches
named.cxx
1#include <cgv/base/named.h>
2
3namespace cgv {
4 namespace base {
5
6named::named(const std::string& _name) : name(_name)
7{
8}
9const std::string& named::get_name() const
10{
11 return name;
12}
13void named::set_name(const std::string& _name)
14{
15 name = _name;
16}
18{
19 return named_ptr(this);
20}
25std::string named::get_type_name() const
26{
27 return "named";
28}
29
30 }
31}
void set_name(const std::string &_name)
set a new parent node
Definition named.cxx:13
named_ptr get_named()
cast upward to named
Definition named.cxx:17
named(const std::string &name="")
construct from name
Definition named.cxx:6
const std::string & get_name() const
return the parent node
Definition named.cxx:9
std::string get_type_name() const
overload to return the type name of this object
Definition named.cxx:25
std::string name
store the name as a string
Definition named.h:25
const_named_ptr get_named_const()
cast upward to const named
Definition named.cxx:21
complete implementation of method actions that only call one method when entering a node
Definition action.h:113
reference counted pointer, which can work together with types that are derived from ref_counted,...
Definition ref_ptr.h:160
data::ref_ptr< named, true > named_ptr
ref counted pointer to a node
Definition named.h:13
the cgv namespace
Definition print.h:11