1 // Copyright (c) 2004-2009 Nokia Corporation and/or its subsidiary(-ies).
2 // All rights reserved.
3 // This component and the accompanying materials are made available
4 // under the terms of "Eclipse Public License v1.0"
5 // which accompanies this distribution, and is available
6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
8 // Initial Contributors:
9 // Nokia Corporation - initial contribution.
20 inline TBool RPacketContext::TPacketFilterV3::IsPresent(TPacketFilterDataBitmapPos aDataMemberBitmapPos)
22 This method may be called by the client application.
23 Checks if the bitmap of a certain attribute is set or not.
25 @param aDataMemberBitmapPos Bitmap of an attribute.
29 return aDataMemberBitmapPos & iPresentDataBitmap;
32 inline void RPacketContext::TPacketFilterV3::Reset(TPacketFilterDataBitmapPos aDataMemberBitmapPos)
34 This method may be called by the client application.
35 Resets the iPresentDataBitmap of an attribute accordign to its Bitmap value.
37 @param aDataMemberBitmapPos Bitmap of an attribute.
41 iPresentDataBitmap &= ~aDataMemberBitmapPos;
44 inline void RPacketContext::TPacketFilterV3::Reset()
46 This method may be called by the client application.
47 Sets the iPresentDataBitmap to 0.
51 iPresentDataBitmap = 0;
54 inline TInt RPacketContext::TPacketFilterV3::ProtocolNumberOrNextHeader()
56 This method may be called by the client application.
57 Gets the iProtocolNumberOrNextHeader value which has been set by the
58 SetProtocolNumberOrNextHeader method.
62 return iProtocolNumberOrNextHeader;
65 inline TInt RPacketContext::TPacketFilterV3::SrcPortMin()
67 This method may be called by the client application.
68 Gets the iSrcPortMin value which has been set by the
76 inline TInt RPacketContext::TPacketFilterV3::SrcPortMax()
78 This method may be called by the client application.
79 Gets the iSrcPortMax value which has been set by the
87 inline TInt RPacketContext::TPacketFilterV3::DestPortMin()
89 This method may be called by the client application.
90 Gets the iDestPortMin value which has been set by the
91 SetDestPortMin method.
98 inline TInt RPacketContext::TPacketFilterV3::DestPortMax()
100 This method may be called by the client application.
101 Gets the iDestPortMax value which has been set by the
102 SetDestPortMax method.
109 inline TUint32 RPacketContext::TPacketFilterV3::SPI()
111 This method may be called by the client application.
112 Gets the iIPSecSPI value which has been set by the
120 inline TUint16 RPacketContext::TPacketFilterV3::TOSorTrafficClass()
122 This method may be called by the client application.
123 Gets the iTOSorTrafficClass value which has been set by the
124 SetTOSorTrafficClass method.
128 return iTOSorTrafficClass;
131 inline TUint32 RPacketContext::TPacketFilterV3::FlowLabel()
133 This method may be called by the client application.
134 Gets the iFlowLabel value which has been set by the
145 inline RPacketContext::TPcoId::TPcoId():iId(0)
149 Constructor that initialises Id by provoded value.
151 @param aId Id ofIE identifier.
153 inline RPacketContext::TPcoId::TPcoId(TUint16 aId):iId(aId)
159 @param aId PCO Id to set.
161 inline void RPacketContext::TPcoId::SetId(TUint16 aId)
171 inline TUint16 RPacketContext::TPcoId::Id() const
177 Compares whether the PCO Id of other PCoId is the same.
179 @param PCO Id to compare.
181 inline TBool RPacketContext::TPcoId::IsEqual(const MTlvItemIdType& aOtherIdType) const
183 return iId==(static_cast<const TPcoId&>(aOtherIdType)).Id();
187 Length of serialised data.
189 @return Length of id when serialized.
191 inline TUint RPacketContext::TPcoId::SerializedLength()const
193 return sizeof(TUint16);
197 Serialise to the descriptor provided
199 Converts internally stored little-endian data
200 to big-endian encoded data as specified in 3GPP TS 24.008, table 10.5.154.
202 @param aData On completion contains serialized PCO item identifier.
204 inline void RPacketContext::TPcoId::ExternalizeL(TDes8& aData) const
207 User::Leave(KErrOverflow);
208 aData[0]=(iId & 0xff00)>>8;
213 Internalize data from the buffer provided.
215 Converts internally stored little-endian data
216 to big-endian encoded data as specified in 3GPP TS 24.008, table 10.5.154.
218 @param aData Buffer containing PCO item Id to be internalized.
220 inline void RPacketContext::TPcoId::InternalizeL(TDesC8& aData)
223 User::Leave(KErrUnderflow);
229 Constructor initialise length by provided value.
231 @param aLen Length of PCO item.
233 inline RPacketContext::TPcoItemDataLength::TPcoItemDataLength(TUint8 aLen):iDataLength(aLen)
239 inline RPacketContext::TPcoItemDataLength::TPcoItemDataLength():iDataLength(0)
243 Sets length of associated data.
245 @param aLength Length of PCO item.
247 inline void RPacketContext::TPcoItemDataLength::SetDataLength(TUint aLength)
249 iDataLength=(TUint8)aLength;
253 Length when serialised.
255 @return Seriliazed length.
257 inline TUint RPacketContext::TPcoItemDataLength::SerializedLength() const
259 return sizeof(TUint8);
263 Length of associated item data.
265 @return Length of PCO item.
267 inline TUint RPacketContext::TPcoItemDataLength::DataLength() const
273 Serialize data member into provoded descriptor.
275 @param aData buffer into which length will be serialized.
277 inline void RPacketContext::TPcoItemDataLength::ExternalizeL(TDes8& aData) const
280 User::Leave(KErrOverflow);
281 aData[0]=iDataLength;
285 Deserialize data from provided buffer
287 @param aData Buffer containing length to be internalized.
289 inline void RPacketContext::TPcoItemDataLength::InternalizeL(TDesC8& aData)
292 User::Leave(KErrUnderflow);
293 iDataLength=aData[0];