11 #include "rofl/common/cmemory.h"
12 #include "rofl/common/logging.h"
13 #include "rofl/common/caddress.h"
14 #include "rofl/common/croflexception.h"
15 #include "rofl/common/protocols/clldpattr.h"
16 #include "rofl/common/protocols/clldpattrs.h"
33 static unsigned int const LLDP_ETHER_TYPE = 0x88cc;
71 pack(uint8_t *buf = (uint8_t*)0,
size_t buflen = 0);
77 unpack(uint8_t *buf,
size_t buflen);
85 set_attrs() {
return attrs; };
91 get_attrs()
const {
return attrs; };
97 set_eth_dst() {
return eth_dst; };
103 get_eth_dst()
const {
return eth_dst; };
109 set_eth_src() {
return eth_src; };
115 get_eth_src()
const {
return eth_src; };
121 get_eth_type()
const {
return eth_type; };
127 set_eth_type() {
return eth_type; };
133 operator<< (std::ostream& os,
clldpmsg const& msg) {
134 os <<
rofl::indent(0) <<
"<clldpmsg length:" << msg.length() <<
" >" << std::endl;
135 os <<
rofl::indent(2) <<
"<eth-dst: " << msg.get_eth_dst() <<
" >" << std::endl;
136 os <<
rofl::indent(2) <<
"<eth-src: " << msg.get_eth_src() <<
" >" << std::endl;
137 os <<
rofl::indent(2) <<
"<eth-type: 0x" << std::hex << (int)msg.get_eth_type() << std::dec <<
" >" << std::endl;
139 os << msg.get_attrs();
Definition: clldpmsg.h:22
Definition: caddress.h:152
Definition: clldpmsg.h:23
Definition: clldpmsg.h:26
Definition: clldpattrs.h:25
Definition: clldpmsg.h:24
Definition: croflexception.h:27