1 // Copyright (c) 2003-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 the License "Symbian Foundation License v1.0" to Symbian Foundation members and "Symbian Foundation End User License Agreement v1.0" to non-members
5 // which accompanies this distribution, and is available
6 // at the URL "http://www.symbianfoundation.org/legal/licencesv10.html".
8 // Initial Contributors:
9 // Nokia Corporation - initial contribution.
16 #if !(defined __CONNPREF_H__)
17 #define __CONNPREF_H__
19 #define TCommSnapPref TConnSnapPref
26 const TUint KMaxConnPrefSize = 0x40;
33 TInt16 iExtensionId; ///< Extension ID
37 class TConnPref : public TBuf8<KMaxConnPrefSize>
39 Overrides the connection preferences.
47 EConnPrefUnknown = 0x00, ///< Unknown Connection preference
48 EConnPrefCommDb = 0x01, ///< CommDb Connection preference
49 EConnPrefCommDbMulti = 0x02, ///< CommDbMulti Connection preferenc
51 EConnPrefIdList = 0x04,
52 EConnPrefSip = 0x05 ///< Sip Connection preference
56 IMPORT_C TConnPref(TInt aExtensionId);
58 IMPORT_C TInt ExtensionId() const;
59 IMPORT_C TInt GetUserLen();
62 IMPORT_C void SetExtensionId(TInt aExtensionId);
63 IMPORT_C void SetUserLen(TInt aLen);
64 inline TUint8* UserPtr() const;
67 inline SConnPref* BasePtr() const;
70 inline SConnPref* TConnPref::BasePtr() const
72 return (SConnPref*)iBuf;
75 inline TUint8* TConnPref::UserPtr() const
77 return (TUint8*)(BasePtr()+1);
80 class TConnSnapPref : public TConnPref
82 An instance of the class is passed to RConnection::Start when user wants to start connection based on
83 Service Network Access Point that represents a collection of AP to try out.
87 @see RConnection::Start
91 IMPORT_C TConnSnapPref();
92 IMPORT_C TConnSnapPref(TUint32 aSnap);
94 IMPORT_C void SetSnap(TUint32 aSnap);
95 IMPORT_C TUint32 Snap() const;
98 #endif // __CONNPREF_H__