Revised OpenFlow Library  v0.6.0dev
 All Classes Files Functions Variables Friends Groups Pages
cofmsg_group_features_stats.h
1 /*
2  * cofmsg_group_features_stats.h
3  *
4  * Created on: 18.03.2013
5  * Author: andi
6  */
7 
8 #ifndef COFMSG_GROUP_FEATURES_STATS_H_
9 #define COFMSG_GROUP_FEATURES_STATS_H_ 1
10 
11 #include "rofl/common/openflow/messages/cofmsg_stats.h"
12 #include "rofl/common/openflow/cofgroupfeaturesstats.h"
13 
14 namespace rofl {
15 namespace openflow {
16 
22 {
23 private:
24 
25 public:
26 
27 
32  uint8_t of_version = 0,
33  uint32_t xid = 0,
34  uint16_t flags = 0);
35 
36 
42 
43 
48  operator= (
50 
51 
55  virtual
57 
58 
63 
64 
68  virtual void
69  reset();
70 
71 
75  virtual uint8_t*
76  resize(size_t len);
77 
78 
82  virtual size_t
83  length() const;
84 
85 
89  virtual void
90  pack(uint8_t *buf = (uint8_t*)0, size_t buflen = 0);
91 
92 
96  virtual void
97  unpack(uint8_t *buf, size_t buflen);
98 
99 
102  virtual void
103  validate();
104 
105 public:
106 
107  friend std::ostream&
108  operator<< (std::ostream& os, cofmsg_group_features_stats_request const& msg) {
109  os << dynamic_cast<cofmsg const&>( msg );
110  os << indent(2) << "<cofmsg_group_features_stats_request >" << std::endl;
111  return os;
112  };
113 };
114 
115 
116 
121  public cofmsg_stats_reply
122 {
123 private:
124 
125  cofgroup_features_stats_reply group_features_stats;
126 
127  union {
128  uint8_t* ofhu_group_features_stats;
129  struct openflow12::ofp_group_features_stats* ofhu12_group_features_stats;
130  // TODO: OF1.3
131  } ofhu;
132 
133 #define ofh_group_features_stats ofhu.ofhu_group_features_stats
134 #define ofh12_group_features_stats ofhu.ofhu12_group_features_stats
135 // TODO OF1.3
136 
137 public:
138 
139 
144  uint8_t of_version = 0,
145  uint32_t xid = 0,
146  uint16_t flags = 0,
147  cofgroup_features_stats_reply const& group_features_stats = cofgroup_features_stats_reply());
148 
149 
154  cofmsg_group_features_stats_reply const& stats);
155 
156 
161  operator= (
162  cofmsg_group_features_stats_reply const& stats);
163 
164 
168  virtual
170 
171 
176 
177 
181  virtual void
182  reset();
183 
184 
188  virtual uint8_t*
189  resize(size_t len);
190 
191 
195  virtual size_t
196  length() const;
197 
198 
202  virtual void
203  pack(uint8_t *buf = (uint8_t*)0, size_t buflen = 0);
204 
205 
209  virtual void
210  unpack(uint8_t *buf, size_t buflen);
211 
212 
215  virtual void
216  validate();
217 
218 
219 public:
220 
221 
226  get_group_features_stats();
227 
228 
229 public:
230 
231  friend std::ostream&
232  operator<< (std::ostream& os, cofmsg_group_features_stats_reply const& msg) {
233  os << dynamic_cast<cofmsg const&>( msg );
234  os << indent(2) << "<cofmsg_group_features_stats_reply >" << std::endl;
235  indent i(4);
236  os << msg.group_features_stats;
237  return os;
238  };
239 };
240 
241 } // end of namespace openflow
242 } // end of namespace rofl
243 
244 #endif /* COFMSG_GROUP_FEATURES_STATS_H_ */
virtual size_t length() const
Definition: cofmsg_group_features_stats.cc:267
cofmsg_group_features_stats_request(uint8_t of_version=0, uint32_t xid=0, uint16_t flags=0)
Definition: cofmsg_group_features_stats.cc:5
virtual void validate()
Definition: cofmsg_group_features_stats.cc:324
virtual size_t length() const
Definition: cofmsg_group_features_stats.cc:84
Definition: cofmsg_stats.h:264
virtual void pack(uint8_t *buf=(uint8_t *) 0, size_t buflen=0)
Definition: cofmsg_group_features_stats.cc:102
virtual ~cofmsg_group_features_stats_reply()
Definition: cofmsg_group_features_stats.cc:232
Definition: cofmsg_stats.h:187
virtual void unpack(uint8_t *buf, size_t buflen)
Definition: cofmsg_group_features_stats.cc:129
virtual void unpack(uint8_t *buf, size_t buflen)
Definition: cofmsg_group_features_stats.cc:314
Definition: openflow12.h:1529
virtual ~cofmsg_group_features_stats_request()
Definition: cofmsg_group_features_stats.cc:60
Definition: cofmsg_group_features_stats.h:120
Definition: cofgroupfeaturesstats.h:21
virtual void validate()
Definition: cofmsg_group_features_stats.cc:139
Definition: cofmsg_group_features_stats.h:20
virtual void reset()
Definition: cofmsg_group_features_stats.cc:240
virtual void reset()
Definition: cofmsg_group_features_stats.cc:68
C++ abstraction for malloc'ed memory areas.
Definition: cmemory.h:44
cofmsg_group_features_stats_reply(uint8_t of_version=0, uint32_t xid=0, uint16_t flags=0, cofgroup_features_stats_reply const &group_features_stats=cofgroup_features_stats_reply())
Definition: cofmsg_group_features_stats.cc:161
virtual void pack(uint8_t *buf=(uint8_t *) 0, size_t buflen=0)
Definition: cofmsg_group_features_stats.cc:285
Definition: logging.h:76