OverSim
DiscoveryMode_m.h
Go to the documentation of this file.
1 //
2 // Generated file, do not edit! Created by opp_msgc 4.2 from common/DiscoveryMode.msg.
3 //
4 
5 #ifndef _DISCOVERYMODE_M_H_
6 #define _DISCOVERYMODE_M_H_
7 
8 #include <omnetpp.h>
9 
10 // opp_msgc version check
11 #define MSGC_VERSION 0x0402
12 #if (MSGC_VERSION!=OMNETPP_VERSION)
13 # error Version mismatch! Probably this file was generated by an earlier version of opp_msgc: 'make clean' should help.
14 #endif
15 
16 // cplusplus {{
17 #include <CommonMessages_m.h>
18 // }}
19 
20 
21 
35 };
36 
48 {
49  protected:
50  unsigned int nodesType_var;
52  int index_var;
53 
54  private:
55  void copy(const DiscoveryCall& other);
56 
57  protected:
58  // protected and unimplemented operator==(), to prevent accidental usage
59  bool operator==(const DiscoveryCall&);
60 
61  public:
62  DiscoveryCall(const char *name=NULL, int kind=0);
63  DiscoveryCall(const DiscoveryCall& other);
64  virtual ~DiscoveryCall();
65  DiscoveryCall& operator=(const DiscoveryCall& other);
66  virtual DiscoveryCall *dup() const {return new DiscoveryCall(*this);}
67  virtual void parsimPack(cCommBuffer *b);
68  virtual void parsimUnpack(cCommBuffer *b);
69 
70  // field getter/setter methods
71  virtual unsigned int getNodesType() const;
72  virtual void setNodesType(unsigned int nodesType);
73  virtual int getNumberOfNodes() const;
74  virtual void setNumberOfNodes(int numberOfNodes);
75  virtual int getIndex() const;
76  virtual void setIndex(int index);
77 };
78 
79 inline void doPacking(cCommBuffer *b, DiscoveryCall& obj) {obj.parsimPack(b);}
80 inline void doUnpacking(cCommBuffer *b, DiscoveryCall& obj) {obj.parsimUnpack(b);}
81 
92 {
93  protected:
94  TransportAddress *nodes_var; // array ptr
95  unsigned int nodes_arraysize;
97 
98  private:
99  void copy(const DiscoveryResponse& other);
100 
101  protected:
102  // protected and unimplemented operator==(), to prevent accidental usage
103  bool operator==(const DiscoveryResponse&);
104 
105  public:
106  DiscoveryResponse(const char *name=NULL, int kind=0);
107  DiscoveryResponse(const DiscoveryResponse& other);
108  virtual ~DiscoveryResponse();
110  virtual DiscoveryResponse *dup() const {return new DiscoveryResponse(*this);}
111  virtual void parsimPack(cCommBuffer *b);
112  virtual void parsimUnpack(cCommBuffer *b);
113 
114  // field getter/setter methods
115  virtual void setNodesArraySize(unsigned int size);
116  virtual unsigned int getNodesArraySize() const;
117  virtual TransportAddress& getNodes(unsigned int k);
118  virtual const TransportAddress& getNodes(unsigned int k) const {return const_cast<DiscoveryResponse*>(this)->getNodes(k);}
119  virtual void setNodes(unsigned int k, const TransportAddress& nodes);
120  virtual int getMaxIndex() const;
121  virtual void setMaxIndex(int maxIndex);
122 };
123 
124 inline void doPacking(cCommBuffer *b, DiscoveryResponse& obj) {obj.parsimPack(b);}
125 inline void doUnpacking(cCommBuffer *b, DiscoveryResponse& obj) {obj.parsimUnpack(b);}
126 
127 
128 #endif // _DISCOVERYMODE_M_H_