C++ main module for gpm Package  1.0
GPM_ModelPort.h
Go to the documentation of this file.
1 #ifndef GPM_ModelPort_H
2 #define GPM_ModelPort_H
3 
4 
5 #include "GPM_Port.h"
6 
8 
9 
19 class GPM_ModelPort : public virtual GPM_Port, public virtual GPM_ModelGraphElement {
20 
21  SP_OBJECT(GPM_ModelPort);
22  // ATTRIBUTES
23 
24 public:
25 
26 
27 
28 private:
29 
30 
31 protected:
32  // METHODS
33 
34  // CONSTRUCTORS
35 
38  GPM_ModelPort(void);
39 
40 
41 
42  // DESTRUCTORS
43 
44 
47  virtual ~GPM_ModelPort(void);
48 
49 
50 
51 public:
54  inline static SP::GPM_ModelPort New() {
55  SP::GPM_ModelPort p(new GPM_ModelPort(),GPM_ModelPort::Delete());
56  p->setThis(p);
57  return p;
58  };
61  virtual SP::GPM_GraphElement NewInstance() const {
62  return New();
63  }
66  virtual void copy(const GPM_GraphElement& node) {
67  GPM_Port::copy(node);
68  const GPM_ModelGraphElement *modelGraphElement=dynamic_cast<const GPM_ModelGraphElement*>(&node);
69  if (modelGraphElement!=null) GPM_ModelGraphElement::copy(*modelGraphElement);
70  }
71 
74  virtual void updateEnvironment(const map<tString,SP::GPM_Variable>& env) {
77 
78  }
79 
80 
81 };
82 
83 #endif
This class describes a model GraphElement interface.
Definition: GPM_ModelGraphElement.h:21
static SP::GPM_ModelPort New()
create a test class
Definition: GPM_ModelPort.h:54
DEFINE_SPTR(GPM_ModelPort)
virtual void updateEnvironment(const map< tString, SP::GPM_Variable > &env)
update the environment
Definition: GPM_ModelGraphElement.cpp:29
#define null
Definition: types.h:13
virtual void updateEnvironment(const map< tString, SP::GPM_Variable > &env)
update the environment
Definition: GPM_ModelPort.h:74
This class describes a port.
Definition: GPM_Port.h:16
virtual SP::GPM_GraphElement NewInstance() const
create a new instance
Definition: GPM_ModelPort.h:61
virtual void copy(const GPM_GraphElement &node)
copy
Definition: GPM_ModelPort.h:66
virtual ~GPM_ModelPort(void)
destroy
Definition: GPM_ModelPort.cpp:7
This class describes a model Port.
Definition: GPM_ModelPort.h:19
virtual void copy(const GPM_GraphElement &node)
copy
Definition: GPM_Port.cpp:14
virtual void updateEnvironment(const map< tString, SP::GPM_Variable > &env)
update environment
Definition: GPM_GraphElement.cpp:114
GPM_ModelPort(void)
create
Definition: GPM_ModelPort.cpp:4
This class describes an element of a graph.
Definition: GPM_GraphElement.h:17
virtual void copy(const GPM_ModelGraphElement &vertex)
copy
Definition: GPM_ModelGraphElement.cpp:13
class Free introduced for deleting a smart pointer
Definition: CORE_Object.h:106