87 * |
91 * |
88 * Convert an instance of this class to a polymorphic Address instance. |
92 * Convert an instance of this class to a polymorphic Address instance. |
89 */ |
93 */ |
90 Address ConvertTo (void) const; |
94 Address ConvertTo (void) const; |
91 static uint8_t GetType (void); |
95 static uint8_t GetType (void); |
|
96 friend bool operator < (const Mac64Address &a, const Mac64Address &b); |
|
97 friend bool operator == (const Mac64Address &a, const Mac64Address &b); |
|
98 friend bool operator != (const Mac64Address &a, const Mac64Address &b); |
|
99 friend std::istream& operator>> (std::istream& is, Mac64Address & address); |
|
100 |
92 uint8_t m_address[8]; |
101 uint8_t m_address[8]; |
93 }; |
102 }; |
94 |
103 |
95 bool operator == (const Mac64Address &a, const Mac64Address &b); |
104 /** |
96 bool operator != (const Mac64Address &a, const Mac64Address &b); |
105 * \class ns3::Mac64AddressValue |
|
106 * \brief hold objects of type ns3::Mac64Address |
|
107 */ |
|
108 |
|
109 ATTRIBUTE_HELPER_HEADER (Mac64Address); |
|
110 |
|
111 inline bool operator == (const Mac64Address &a, const Mac64Address &b) |
|
112 { |
|
113 return memcmp (a.m_address, b.m_address, 8) == 0; |
|
114 } |
|
115 inline bool operator != (const Mac64Address &a, const Mac64Address &b) |
|
116 { |
|
117 return memcmp (a.m_address, b.m_address, 8) != 0; |
|
118 } |
|
119 inline bool operator < (const Mac64Address &a, const Mac64Address &b) |
|
120 { |
|
121 return memcmp (a.m_address, b.m_address, 8) < 0; |
|
122 } |
|
123 |
97 std::ostream& operator<< (std::ostream& os, const Mac64Address & address); |
124 std::ostream& operator<< (std::ostream& os, const Mac64Address & address); |
|
125 std::istream& operator>> (std::istream& is, Mac64Address & address); |
98 |
126 |
99 } // namespace ns3 |
127 } // namespace ns3 |
100 |
128 |
101 #endif /* MAC64_ADDRESS_H */ |
129 #endif /* MAC64_ADDRESS_H */ |