sl@0
|
1 |
// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
|
sl@0
|
2 |
// All rights reserved.
|
sl@0
|
3 |
// This component and the accompanying materials are made available
|
sl@0
|
4 |
// under the terms of "Eclipse Public License v1.0"
|
sl@0
|
5 |
// which accompanies this distribution, and is available
|
sl@0
|
6 |
// at the URL "http://www.eclipse.org/legal/epl-v10.html".
|
sl@0
|
7 |
//
|
sl@0
|
8 |
// Initial Contributors:
|
sl@0
|
9 |
// Nokia Corporation - initial contribution.
|
sl@0
|
10 |
//
|
sl@0
|
11 |
// Contributors:
|
sl@0
|
12 |
//
|
sl@0
|
13 |
// Description:
|
sl@0
|
14 |
//
|
sl@0
|
15 |
|
sl@0
|
16 |
|
sl@0
|
17 |
|
sl@0
|
18 |
// INCLUDE FILES
|
sl@0
|
19 |
#include <s32file.h>
|
sl@0
|
20 |
#include "featmgrfeatureentry.h"
|
sl@0
|
21 |
|
sl@0
|
22 |
// ============================= LOCAL FUNCTIONS ===============================
|
sl@0
|
23 |
|
sl@0
|
24 |
// ============================ MEMBER FUNCTIONS ===============================
|
sl@0
|
25 |
|
sl@0
|
26 |
// -----------------------------------------------------------------------------
|
sl@0
|
27 |
// TFeatureServerEntry::TFeatureServerEntry()
|
sl@0
|
28 |
// -----------------------------------------------------------------------------
|
sl@0
|
29 |
//
|
sl@0
|
30 |
TFeatureServerEntry::TFeatureServerEntry() :
|
sl@0
|
31 |
iFeatureID( TUid::Uid(0) ), iFlags( 0 ), iData( 0 )
|
sl@0
|
32 |
{
|
sl@0
|
33 |
}
|
sl@0
|
34 |
|
sl@0
|
35 |
// -----------------------------------------------------------------------------
|
sl@0
|
36 |
// TFeatureServerEntry::TFeatureServerEntry()
|
sl@0
|
37 |
// -----------------------------------------------------------------------------
|
sl@0
|
38 |
//
|
sl@0
|
39 |
TFeatureServerEntry::TFeatureServerEntry( TUid aFeature ) :
|
sl@0
|
40 |
iFeatureID( aFeature ), iFlags( 0 ), iData( 0 )
|
sl@0
|
41 |
{
|
sl@0
|
42 |
}
|
sl@0
|
43 |
|
sl@0
|
44 |
// -----------------------------------------------------------------------------
|
sl@0
|
45 |
// TFeatureServerEntry::TFeatureServerEntry()
|
sl@0
|
46 |
// -----------------------------------------------------------------------------
|
sl@0
|
47 |
//
|
sl@0
|
48 |
TFeatureServerEntry::TFeatureServerEntry( TUid aFeature,
|
sl@0
|
49 |
TBitFlags32 aFlags, TUint32 aData ) :
|
sl@0
|
50 |
iFeatureID( aFeature ), iFlags( aFlags ), iData( aData )
|
sl@0
|
51 |
{
|
sl@0
|
52 |
}
|
sl@0
|
53 |
|
sl@0
|
54 |
// -----------------------------------------------------------------------------
|
sl@0
|
55 |
// TFeatureServerEntry::TFeatureServerEntry()
|
sl@0
|
56 |
// -----------------------------------------------------------------------------
|
sl@0
|
57 |
//
|
sl@0
|
58 |
TFeatureServerEntry::TFeatureServerEntry( TFeatureEntry& aFeature ) :
|
sl@0
|
59 |
iFeatureID( aFeature.FeatureUid() ),
|
sl@0
|
60 |
iFlags( aFeature.FeatureFlags() ),
|
sl@0
|
61 |
iData( aFeature.FeatureData() )
|
sl@0
|
62 |
{
|
sl@0
|
63 |
}
|
sl@0
|
64 |
|
sl@0
|
65 |
// -----------------------------------------------------------------------------
|
sl@0
|
66 |
// TFeatureServerEntry::FeatureUid()
|
sl@0
|
67 |
// -----------------------------------------------------------------------------
|
sl@0
|
68 |
//
|
sl@0
|
69 |
TUid TFeatureServerEntry::FeatureUid() const
|
sl@0
|
70 |
{
|
sl@0
|
71 |
return iFeatureID;
|
sl@0
|
72 |
}
|
sl@0
|
73 |
|
sl@0
|
74 |
// -----------------------------------------------------------------------------
|
sl@0
|
75 |
// TFeatureServerEntry::FeatureFlags()
|
sl@0
|
76 |
// -----------------------------------------------------------------------------
|
sl@0
|
77 |
//
|
sl@0
|
78 |
TBitFlags32 TFeatureServerEntry::FeatureFlags() const
|
sl@0
|
79 |
{
|
sl@0
|
80 |
return iFlags;
|
sl@0
|
81 |
}
|
sl@0
|
82 |
|
sl@0
|
83 |
// -----------------------------------------------------------------------------
|
sl@0
|
84 |
// TFeatureServerEntry::FeatureData()
|
sl@0
|
85 |
// -----------------------------------------------------------------------------
|
sl@0
|
86 |
//
|
sl@0
|
87 |
TUint32 TFeatureServerEntry::FeatureData() const
|
sl@0
|
88 |
{
|
sl@0
|
89 |
return iData;
|
sl@0
|
90 |
}
|
sl@0
|
91 |
|
sl@0
|
92 |
// -----------------------------------------------------------------------------
|
sl@0
|
93 |
// TFeatureServerEntry::InternalizeL()
|
sl@0
|
94 |
// -----------------------------------------------------------------------------
|
sl@0
|
95 |
//
|
sl@0
|
96 |
void TFeatureServerEntry::InternalizeL( RReadStream& aStream )
|
sl@0
|
97 |
{
|
sl@0
|
98 |
iFeatureID = TUid::Uid( aStream.ReadUint32L() );
|
sl@0
|
99 |
iFlags = aStream.ReadUint32L();
|
sl@0
|
100 |
iData = aStream.ReadUint32L();
|
sl@0
|
101 |
}
|
sl@0
|
102 |
|
sl@0
|
103 |
// -----------------------------------------------------------------------------
|
sl@0
|
104 |
// TFeatureServerEntry::ExternalizeL()
|
sl@0
|
105 |
// -----------------------------------------------------------------------------
|
sl@0
|
106 |
//
|
sl@0
|
107 |
void TFeatureServerEntry::ExternalizeL( RWriteStream& aStream ) const
|
sl@0
|
108 |
{
|
sl@0
|
109 |
aStream.WriteUint32L( iFeatureID.iUid );
|
sl@0
|
110 |
aStream.WriteUint32L( iFlags.iFlags );
|
sl@0
|
111 |
aStream.WriteUint32L( iData );
|
sl@0
|
112 |
}
|
sl@0
|
113 |
|
sl@0
|
114 |
// End of File
|