|
1 // Copyright (c) 2007-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". |
|
7 // |
|
8 // Initial Contributors: |
|
9 // Nokia Corporation - initial contribution. |
|
10 // |
|
11 // Contributors: |
|
12 // |
|
13 // Description: |
|
14 // PAN Provisioning information |
|
15 // |
|
16 // |
|
17 |
|
18 /** |
|
19 @file |
|
20 @internalComponent |
|
21 */ |
|
22 |
|
23 #ifndef SYMBIAN_PANPROVISIONINFO_H |
|
24 #define SYMBIAN_PANPROVISIONINFO_H |
|
25 |
|
26 #include <e32std.h> |
|
27 #include <bluetooth/logger.h> |
|
28 #include <comms-infras/metadata.h> |
|
29 |
|
30 #include <elements/nm_node.h> |
|
31 #include <comms-infras/ss_common.h> |
|
32 #include <networking/pktdrv.h> |
|
33 #include <networking/pktdrv_internal.h> |
|
34 |
|
35 NONSHARABLE_CLASS(CPanProvisionInfo) : public CBase, public Meta::SMetaData |
|
36 { |
|
37 enum |
|
38 { |
|
39 EUid = 0x1028376E, |
|
40 ETypeId = 1, |
|
41 }; |
|
42 |
|
43 |
|
44 public: |
|
45 inline CPanProvisionInfo(); |
|
46 |
|
47 ~CPanProvisionInfo() {}; |
|
48 |
|
49 inline const Messages::TNodeId& BnepConnectionMgr(); |
|
50 inline void SetBnepConnectionMgr(const Messages::TNodeId& aConnMgr); |
|
51 |
|
52 inline CPacketDriverOwner& PacketDriverOwner() const; |
|
53 inline void SetPacketDriverOwner(CPacketDriverOwner& aPktDrvOwner); |
|
54 |
|
55 inline void Reset(); |
|
56 |
|
57 DATA_VTABLE |
|
58 |
|
59 private: |
|
60 Messages::TNodeId iBnepConnectionMgr; |
|
61 CPacketDriverOwner* iPktDrvOwner; |
|
62 }; |
|
63 |
|
64 |
|
65 |
|
66 inline CPanProvisionInfo::CPanProvisionInfo() |
|
67 { |
|
68 } |
|
69 |
|
70 inline CPacketDriverOwner& CPanProvisionInfo::PacketDriverOwner() const |
|
71 { |
|
72 #ifdef __FLOG_ACTIVE |
|
73 _LIT8(KLogComponent, LOG_COMPONENT_PAN_PROVIDERS); |
|
74 #endif |
|
75 |
|
76 #ifdef _DEBUG |
|
77 PANICCATEGORY("btprovider"); |
|
78 #endif |
|
79 |
|
80 ASSERT_DEBUG(iPktDrvOwner); |
|
81 return *iPktDrvOwner; |
|
82 } |
|
83 |
|
84 inline void CPanProvisionInfo::SetPacketDriverOwner(CPacketDriverOwner& aPktDrvOwner) |
|
85 { |
|
86 #ifdef __FLOG_ACTIVE |
|
87 _LIT8(KLogComponent, LOG_COMPONENT_PAN_PROVIDERS); |
|
88 #endif |
|
89 |
|
90 #ifdef _DEBUG |
|
91 PANICCATEGORY("btprovider"); |
|
92 #endif |
|
93 |
|
94 ASSERT_DEBUG(!iPktDrvOwner); // should only be set once |
|
95 iPktDrvOwner = &aPktDrvOwner; |
|
96 } |
|
97 |
|
98 |
|
99 inline const Messages::TNodeId& CPanProvisionInfo::BnepConnectionMgr() |
|
100 { |
|
101 return iBnepConnectionMgr; |
|
102 } |
|
103 |
|
104 inline void CPanProvisionInfo::SetBnepConnectionMgr(const Messages::TNodeId& aConnMgr) |
|
105 { |
|
106 iBnepConnectionMgr = aConnMgr; |
|
107 } |
|
108 |
|
109 inline void CPanProvisionInfo::Reset() |
|
110 { |
|
111 iBnepConnectionMgr = Messages::TNodeId::NullId(); |
|
112 iPktDrvOwner = NULL; |
|
113 } |
|
114 |
|
115 #endif |
|
116 // SYMBIAN_PANPROVISIONINFO_H |