class TInet6Packet : public TInet6PacketBase |
Encapsulates an IPv6 packet header as a section of an RMBufChain.
The T template parameter should represent a packet header type. It should support static functions MaxHeaderLength() and MinHeaderLength() that return TInt values for maximum and minimum header lengths respectively.
Public Member Functions | |
---|---|
TInet6Packet(TAlign) | |
TInet6Packet(RMBufChain &) | |
TInet6Packet(RMBufChain &, TInt, TAlign) | |
void | Set(RMBufChain &, TInt, TInt) |
T & | operator()() |
Inherited Functions | |
---|---|
TInet6PacketBase::Access(RMBufChain &,TInt,TInt,TInt) | |
TInet6PacketBase::SetAlign(TAlign) | |
TInet6PacketBase::TInet6PacketBase(TAlign) |
Inherited Enumerations | |
---|---|
TInet6PacketBase:TAlign |
Public Attributes | |
---|---|
T * | iHdr |
Inherited Attributes | |
---|---|
TInet6PacketBase::iAlign | |
TInet6PacketBase::iLength |
TInet6Packet | ( | TAlign | aAlign = EAlign4 | ) | [inline] |
Default constructor.
Construct an empty mapping. To be usable, the Set() function must be used.
TAlign aAlign = EAlign4 |
TInet6Packet | ( | RMBufChain & | aPacket | ) | [inline] |
Constructor specifying a RMBufChain object.
Verify and arrange it so that a class T can be mapped to a contiguous octets from the beginning of the RMBufChain content, and set iHdr to point this area.
If this is not possible, iHdr is initialized to NULL.
RMBufChain & aPacket | Packet containing the header T at offset = 0 |
TInet6Packet | ( | RMBufChain & | aPacket, |
TInt | aOffset, | ||
TAlign | aAlign = EAlign4 | ||
) | [inline] |
Constructor specifying a RMBufChain object and an offset.
Verify and arrange it so that a class T can be mapped to a contiguous octets starting at specified offset of the RMBufChain content, and set iHdr to point this area.
If this is not possible, iHdr is initialized to NULL.
RMBufChain & aPacket | Packet containing the header T at aOffset |
TInt aOffset | Offset of the header to be mapped. |
TAlign aAlign = EAlign4 | The alignement requirement. |
void | Set | ( | RMBufChain & | aPacket, |
TInt | aOffset, | |||
TInt | aSize | |||
) | [inline] |
Sets the packet header from a specified RMBufChain object.
Verify and arrange it so that a aSize octets can be mapped to a contiguous octets starting at specified offset of the RMBufChain content, and set iHdr to point this area.
If this is not possible, iHdr is initialized to NULL.
Note that this differs from the contructors: the required size is a parameter, and not determined by the T::MinHeaderLength(). However, the "T* iHdr" is set to point the start of the requested area. It's a responsibility of the user of this method to know whether using this pointer is safe with the specified size parameter.
RMBufChain & aPacket | Packet containing the header T at aOffset |
TInt aOffset | Offset (position) of the header to be mapped |
TInt aSize | Length of required contiguous memory |
T * | iHdr |
The pointer to the mapped region (if non-NULL). If NULL, then there is no mapping, and iLength == 0.
Copyright ©2010 Nokia Corporation and/or its subsidiary(-ies).
All rights
reserved. Unless otherwise stated, these materials are provided under the terms of the Eclipse Public License
v1.0.