|
INET Framework for OMNeT++/OMNEST
|
00001 // 00002 // Generated file, do not edit! Created by opp_msgc 4.2 from networklayer/rsvp_te/RSVPPacket.msg. 00003 // 00004 00005 #ifndef _RSVPPACKET_M_H_ 00006 #define _RSVPPACKET_M_H_ 00007 00008 #include <omnetpp.h> 00009 00010 // opp_msgc version check 00011 #define MSGC_VERSION 0x0402 00012 #if (MSGC_VERSION!=OMNETPP_VERSION) 00013 # error Version mismatch! Probably this file was generated by an earlier version of opp_msgc: 'make clean' should help. 00014 #endif 00015 00016 // cplusplus {{ 00017 #include "IntServ_m.h" 00018 00019 #define PATH_MESSAGE 1 00020 #define RESV_MESSAGE 2 00021 #define PTEAR_MESSAGE 3 00022 #define RTEAR_MESSAGE 4 00023 #define PERROR_MESSAGE 5 00024 #define RERROR_MESSAGE 6 00025 #define HELLO_MESSAGE 7 00026 // }} 00027 00028 00029 00039 class RSVPMessage : public ::cPacket 00040 { 00041 protected: 00042 int rsvpKind_var; 00043 00044 private: 00045 void copy(const RSVPMessage& other); 00046 00047 protected: 00048 // protected and unimplemented operator==(), to prevent accidental usage 00049 bool operator==(const RSVPMessage&); 00050 00051 public: 00052 RSVPMessage(const char *name=NULL, int kind=0); 00053 RSVPMessage(const RSVPMessage& other); 00054 virtual ~RSVPMessage(); 00055 RSVPMessage& operator=(const RSVPMessage& other); 00056 virtual RSVPMessage *dup() const {return new RSVPMessage(*this);} 00057 virtual void parsimPack(cCommBuffer *b); 00058 virtual void parsimUnpack(cCommBuffer *b); 00059 00060 // field getter/setter methods 00061 virtual int getRsvpKind() const; 00062 virtual void setRsvpKind(int rsvpKind); 00063 }; 00064 00065 inline void doPacking(cCommBuffer *b, RSVPMessage& obj) {obj.parsimPack(b);} 00066 inline void doUnpacking(cCommBuffer *b, RSVPMessage& obj) {obj.parsimUnpack(b);} 00067 00103 class RSVPPacket_Base : public ::RSVPMessage 00104 { 00105 protected: 00106 SessionObj_t session_var; 00107 bool checksumValid_var; 00108 00109 private: 00110 void copy(const RSVPPacket_Base& other); 00111 00112 protected: 00113 // protected and unimplemented operator==(), to prevent accidental usage 00114 bool operator==(const RSVPPacket_Base&); 00115 // make constructors protected to avoid instantiation 00116 RSVPPacket_Base(const char *name=NULL, int kind=0); 00117 RSVPPacket_Base(const RSVPPacket_Base& other); 00118 // make assignment operator protected to force the user override it 00119 RSVPPacket_Base& operator=(const RSVPPacket_Base& other); 00120 00121 public: 00122 virtual ~RSVPPacket_Base(); 00123 virtual RSVPPacket_Base *dup() const {throw cRuntimeError("You forgot to manually add a dup() function to class RSVPPacket");} 00124 virtual void parsimPack(cCommBuffer *b); 00125 virtual void parsimUnpack(cCommBuffer *b); 00126 00127 // field getter/setter methods 00128 virtual SessionObj_t& getSession(); 00129 virtual const SessionObj_t& getSession() const {return const_cast<RSVPPacket_Base*>(this)->getSession();} 00130 virtual void setSession(const SessionObj_t& session); 00131 virtual bool getChecksumValid() const; 00132 virtual void setChecksumValid(bool checksumValid); 00133 }; 00134 00135 00136 #endif // _RSVPPACKET_M_H_