Ipv6Header¶
Namespace: inet
class Ipv6Header
Ipv6 datagram. RFC 2460 Section 3.
Header fields not explicitly modelled:
- payload length: will be calculated from encapsulated message length
and extension headers’ length
Usage diagram¶
Inheritance diagram¶
Extends¶
Name |
Type |
Description |
|---|---|---|
class |
(no description) |
Fields¶
Name |
Type |
Description |
|---|---|---|
id |
int |
|
mutable |
bool |
|
complete |
bool |
|
correct |
bool |
|
properlyRepresented |
bool |
|
chunkLength |
||
rawBin |
string[] |
|
rawHex |
string[] |
|
regionTags |
||
sourceAddress |
||
destinationAddress |
||
protocol |
const Protocol * |
|
chunkLength |
||
version |
uint8_t |
|
srcAddress |
||
destAddress |
||
payloadLength |
The size of the payload in octets, including any extension headers. The length is set to zero when a Hop-by-Hop extension header carries a Jumbo Payload option. |
|
trafficClass |
short |
@bits(8) Traffic Class OMNeT++ 6.0: short __dscp @custom @getter(getDscp) @setter(setDscp); // @bit(6), maps to bits 0-5 of trafficClass short __ecn @custom @getter(getEcn) @setter(setEcn); // @bit(2), maps to bits 6-7 of trafficClass |
flowLabel |
unsigned int |
|
hopLimit |
short |
|
protocolId |
Properties¶
Name |
Value |
Description |
|---|---|---|
beforeChange |
handleChange() |
|
descriptor |
readonly |
|
existingClass |
||
packetData |
Source code¶
//
// Ipv6 datagram. RFC 2460 Section 3.
//
// Header fields not explicitly modelled:
// - payload length: will be calculated from encapsulated message length
// and extension headers' length
//
class Ipv6Header extends NetworkHeaderBase
{
chunkLength = IPv6_HEADER_BYTES;
uint8_t version = 6;
Ipv6Address srcAddress;
Ipv6Address destAddress;
B payloadLength = B(-1); // The size of the payload in octets, including any extension headers. The length is set to zero when a Hop-by-Hop extension header carries a Jumbo Payload option.
short trafficClass; // @bits(8) Traffic Class
// OMNeT++ 6.0:
// short __dscp @custom @getter(getDscp) @setter(setDscp); // @bit(6), maps to bits 0-5 of trafficClass
// short __ecn @custom @getter(getEcn) @setter(setEcn); // @bit(2), maps to bits 6-7 of trafficClass
unsigned int flowLabel;
short hopLimit = 0;
IpProtocolId protocolId = IP_PROT_NONE;
}