CVJDeCompressor Class Reference
| class CVJDeCompressor : public CVJDeCompressorIf |
Van Jacobson TCP/IP header decompressor (RFC 1144)
| Private Member Functions |
|---|
|
TBool
| CheckStoredRxHeader(const TUint) |
| void | ClearFlag(const TUint) |
| void | CopyInNewHeaderL(RMBufChain *, ThdrIP *, ThdrTCP *, TUint, TUint16, TUint16) |
| void | CopyRecvHeader(const TUint, ThdrIP *) |
|
TUint16
| DecodeDelta(TUint8 **) |
| void | DecompAck(TUint8 **, ThdrTCP *) |
| void | DecompIPId(const TUint, TUint8 **, ThdrIP *) |
| void | DecompPushFlag(const TUint, ThdrTCP *) |
| void | DecompSWAU(const TUint, TUint8 **, ThdrTCP *, TUint16) |
| void | DecompSeq(TUint8 **, ThdrTCP *) |
| void | DecompUrgent(TUint8 **, ThdrTCP *, TUint) |
| void | DecompWindow(TUint8 **, ThdrTCP *) |
| void | DecompressFrameL(RMBufChain &, TUint8, TUint8, TUint8 *const , TUint, TUint16) |
| void | DoIPChecksum(ThdrIP *, TUint16) |
| void | EncodeDelta(TUint8 **, TUint16) |
|
ThdrIP * | GetIPHeader(RMBufChain &) |
| void | GetStoredRxHeader(const TUint, ThdrIP *, ThdrTCP *) |
|
TUint8 * | GetVJPtr(RMBufChain &, TUint16 *) |
| void | SetFlag(const TUint) |
|
TBool
| TestFlag(const TUint) |
Constructor & Destructor Documentation
Member Functions Documentation
CRCError()
Sets the discard flag after receiving a bad frame so that future decompressed packets don't get out of sync.
CheckStoredRxHeader(const TUint)
|
TBool
| CheckStoredRxHeader | ( | const TUint | aConnection | ) | const [private] |
Checks if the given VJ connection number has previously been filled in.
Parameters
| const TUint aConnection | Valid VJ connection number to check |
ClearFlag(const TUint)
| void | ClearFlag | ( | const TUint | aFlag | ) | [private, inline] |
Parameters
| const TUint aFlag | Flag value to clear |
ConstructL(CVJCompFactory *, TUint)
Parameters
| CVJCompFactory * aFactory | Factory that created this object |
| TUint aSlots | Value of the highest VJ connection number to be received |
CopyInNewHeaderL(RMBufChain *, ThdrIP *, ThdrTCP *, TUint, TUint16, TUint16)
Copy the uncompressed header into the proper location in the packet.
Parameters
| RMBufChain * aPacket | MBuf chain containing packet to be updated |
| ThdrIP * aIPHeader | IP packet header |
| ThdrTCP * aTCPHeader | TCP header |
| TUint aCompressedHeaderLength | Length of VJ compression header |
| TUint16 aIPHeaderLength | Length of IP header |
| TUint16 aTCPHeaderLength | Length of TCP header |
CopyRecvHeader(const TUint, ThdrIP *)
| void | CopyRecvHeader | ( | const TUint | aConnectionNumber, |
| | ThdrIP * | aHeader |
| | ) | [private] |
Caches a TCP/IP Header to be used as a reference to reconstruct future compressed headers.
Parameters
| const TUint aConnectionNumber | Valid VJ connection number |
| ThdrIP * aHeader | TCP/IP header |
DecodeDelta(TUint8 **)
Decodes a compressed delta value.
Parameters
| TUint8 ** aVJCompHeader | Pointer to pointer into VJ header buffer holding encoded value; returns with pointer incremented one past end of value |
DecompAck(TUint8 **, ThdrTCP *)
| void | DecompAck | ( | TUint8 ** | aVJCompHeader, |
| | ThdrTCP * | aTCPHeader |
| | ) | [private] |
Decompresses the Acknowledgement Number field.
Parameters
| TUint8 ** aVJCompHeader | Pointer to the pointer to the VJ compressed header |
| ThdrTCP * aTCPHeader | TCP header to be updated |
DecompIPId(const TUint, TUint8 **, ThdrIP *)
| void | DecompIPId | ( | const TUint | aChanges, |
| | TUint8 ** | aVJCompHeader, |
| | ThdrIP * | aIPHeader |
| | ) | [private] |
Decompresses the IP Identification field.
Parameters
| const TUint aChanges | The VJ change mask |
| TUint8 ** aVJCompHeader | Pointer to the pointer to the VJ compressed header |
| ThdrIP * aIPHeader | IP packet header to be updated |
DecompPushFlag(const TUint, ThdrTCP *)
| void | DecompPushFlag | ( | const TUint | aChanges, |
| | ThdrTCP * | aHeader |
| | ) | [private] |
Decompresses the Push flag.
Parameters
| const TUint aChanges | The VJ change mask |
| ThdrTCP * aHeader | TCP header to be updated |
DecompSWAU(const TUint, TUint8 **, ThdrTCP *, TUint16)
Decompresses the special case SWAU type packet.
Parameters
| const TUint aChanges | The VJ change mask |
| TUint8 ** aVJCompHeader | Pointer to the pointer to the VJ compressed header |
| ThdrTCP * aTCPHeader | TCP header to be updated |
| TUint16 aPreviousFrameLength | Length of cached packet for this VJ connection |
DecompSeq(TUint8 **, ThdrTCP *)
| void | DecompSeq | ( | TUint8 ** | aVJCompHeader, |
| | ThdrTCP * | aTCPHeader |
| | ) | [private] |
Decompresses the Sequence Number field.
Parameters
| TUint8 ** aVJCompHeader | Pointer to the pointer to the VJ compressed header |
| ThdrTCP * aTCPHeader | TCP header to be updated |
DecompUrgent(TUint8 **, ThdrTCP *, TUint)
Decompresses the Urgent field.
Parameters
| TUint8 ** aVJCompHeader | Pointer to the pointer to the VJ compressed header |
| ThdrTCP * aTCPHeader | TCP header to be updated |
| TUint aChanges | The VJ change mask |
DecompVJComp(RMBufChain &)
DecompVJUncomp(RMBufChain &)
Handles a VJ uncompressed packet. Stores the packet header in the appropriate VJ connection slot.
DecompVJComp
DecompWindow(TUint8 **, ThdrTCP *)
| void | DecompWindow | ( | TUint8 ** | aVJCompHeader, |
| | ThdrTCP * | aTCPHeader |
| | ) | [private] |
Decompresses the Window field.
Parameters
| TUint8 ** aVJCompHeader | Pointer to the pointer to the VJ compressed header |
| ThdrTCP * aTCPHeader | TCP header to be updated |
DecompressFrameL(RMBufChain &, TUint8, TUint8, TUint8 *const, TUint, TUint16)
Uncompresses a VJ compressed TCP/IP header.
-
leave
- KErrCorrupt if aPacket is corrupt
Parameters
| RMBufChain & aPacket | MBuf chain containing packet to be updated |
| TUint8 aConnection | VJ connection number |
| TUint8 aChanges | The VJ change mask |
| TUint8 *const aInitialHeaderPtr | Beginning of the compressed VJ header |
| TUint Offset | Offset from start of packet to TCP checksum field |
| TUint16 aCurrentFrameLength | Length of the compressed packet |
DoIPChecksum(ThdrIP *, TUint16)
| void | DoIPChecksum | ( | ThdrIP * | aIPHeader, |
| | TUint16 | aIPHeaderLength |
| | ) | [private] |
Calculate the IP checksum and store it in the given IP packet header. See RFC 1071.
Parameters
| ThdrIP * aIPHeader | IP packet header |
| TUint16 aIPHeaderLength | Length of IP header in bytes (must be even) |
EncodeDelta(TUint8 **, TUint16)
GetIPHeader(RMBufChain &)
Extracts the IP Header from the packet even though there is a buffer of Info on the front. This is used in VJ, to avoid the awful hack in the main receive path. PRR 20-11-97
GetStoredRxHeader(const TUint, ThdrIP *, ThdrTCP *)
| void | GetStoredRxHeader | ( | const TUint | aConnectionNumber, |
| | ThdrIP * | aIPHeader, |
| | ThdrTCP * | aTCPHeader |
| | ) | [private] |
Retrieves a packet header from the VJ connection cache.
Parameters
| const TUint aConnectionNumber | Valid VJ connection number to retrieve |
| ThdrIP * aIPHeader | IP packet header |
| ThdrTCP * aTCPHeader | TCP header |
GetVJPtr(RMBufChain &, TUint16 *)
Gets a pointer to the VJ Header even though there is a pseudo (Adam) buffer of Info on the front.
Parameters
| RMBufChain & aChain | MBuf chain containing packet |
| TUint16 * aCurrentFrameLength | Returns the length of the packet |
SetFlag(const TUint)
| void | SetFlag | ( | const TUint | aFlag | ) | [private, inline] |
Parameters
| const TUint aFlag | Flag value to set |
TestFlag(const TUint)
Test if an internal flag is set.
Parameters
| const TUint aFlag | Flag value to test |
Member Data Documentation
TUint
iFlags
Set to KVJDiscard while discarding received packets due to lost synchronization
TUint
iLastRxConn
|
TUint
| iLastRxConn | [private] |
VJ connection number of the last valid packet received
TUint
iNumVJSlots
|
TUint
| iNumVJSlots | [private] |
Index of the highest-numbered VJ connection
TVJCompHdr * iRxStates
Pointer to start of array of VJ connections
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.