C++ mpi module for stochmagnet_main Package
EXPR_InheritedNode.h
1 #ifndef EXPR_InheritedNode_H
2 #define EXPR_InheritedNode_H
3 
4 #include "EXPR_ChildNode.h"
5 #include "EXPR_ParentNode.h"
6 
7 
15 class EXPR_InheritedNode : public virtual EXPR_ChildNode , public virtual EXPR_ParentNode {
16 
17 private:
18 
19 
20 
21 
22 private:
23  //associations
24 
25 
26 
27 protected:
28  //builders
29 
33  }
34 
35  //deleters
38  virtual ~EXPR_InheritedNode() {
39 
40  }
41 
42 public:
43  //MEMORY
44  //======
52  virtual tMemSize getMemorySize() const override {
53  return sizeof(*this)+getContentsMemorySize();
54  }
55 
64  virtual tMemSize getContentsMemorySize() const override {
67  return mem;
68  }
69 protected:
70 
71 
72 public:
76  virtual tString toString() const override {
77  std::stringstream ret;
78  ret<<EXPR_ParentNode::toString()<<"\n";
79  return ret.str();
80  }
81 
82 
83 
84 };
85 
86 
87 
88 
89 #endif
90 
91 
This class describes a child node of the tree.
Definition: EXPR_ChildNode.h:12
virtual tMemSize getContentsMemorySize() const override
return nthe memory size of the included associations
Definition: EXPR_ChildNode.h:58
This class describes a child & parent node.
Definition: EXPR_InheritedNode.h:15
virtual ~EXPR_InheritedNode()
delete the class
Definition: EXPR_InheritedNode.h:38
EXPR_InheritedNode()
create the class
Definition: EXPR_InheritedNode.h:32
virtual tMemSize getContentsMemorySize() const override
return nthe memory size of the included associations
Definition: EXPR_InheritedNode.h:64
virtual tMemSize getMemorySize() const override
return the memory size of the class
Definition: EXPR_InheritedNode.h:52
virtual tString toString() const override
return the string representation of this
Definition: EXPR_InheritedNode.h:76
This class is a parent node with children.
Definition: EXPR_ParentNode.h:23
virtual tMemSize getContentsMemorySize() const override
return nthe memory size of the included associations
Definition: EXPR_ParentNode.h:69
virtual tString toString() const override
return the string representation of this
Definition: EXPR_ParentNode.h:169