williamr@2
|
1 |
/*
|
williamr@2
|
2 |
* Copyright (c) 2001-2009 Nokia Corporation and/or its subsidiary(-ies).
|
williamr@2
|
3 |
* All rights reserved.
|
williamr@2
|
4 |
* This component and the accompanying materials are made available
|
williamr@2
|
5 |
* under the terms of the License "Eclipse Public License v1.0"
|
williamr@2
|
6 |
* which accompanies this distribution, and is available
|
williamr@2
|
7 |
* at the URL "http://www.eclipse.org/legal/epl-v10.html".
|
williamr@2
|
8 |
*
|
williamr@2
|
9 |
* Initial Contributors:
|
williamr@2
|
10 |
* Nokia Corporation - initial contribution.
|
williamr@2
|
11 |
*
|
williamr@2
|
12 |
* Contributors:
|
williamr@2
|
13 |
*
|
williamr@2
|
14 |
* Description:
|
williamr@2
|
15 |
*
|
williamr@2
|
16 |
*/
|
williamr@2
|
17 |
|
williamr@2
|
18 |
|
williamr@2
|
19 |
|
williamr@2
|
20 |
|
williamr@2
|
21 |
/**
|
williamr@2
|
22 |
@file
|
williamr@2
|
23 |
@publishedPartner
|
williamr@2
|
24 |
@released
|
williamr@2
|
25 |
*/
|
williamr@2
|
26 |
|
williamr@2
|
27 |
#ifndef __CCTTOKENTYPEINFO_H__
|
williamr@2
|
28 |
#define __CCTTOKENTYPEINFO_H__
|
williamr@2
|
29 |
|
williamr@2
|
30 |
#include <ct/tctalltokentypes.h>
|
williamr@2
|
31 |
#include <ct/tcttokentypeattribute.h>
|
williamr@2
|
32 |
#include <ct/rcpointerarray.h>
|
williamr@2
|
33 |
class CImplementationInformation;
|
williamr@2
|
34 |
|
williamr@2
|
35 |
|
williamr@2
|
36 |
/**
|
williamr@2
|
37 |
* Information about a token type.
|
williamr@2
|
38 |
*
|
williamr@2
|
39 |
* A list of CCTTokenTypeInfo objects can be obtained using the static ListL()
|
williamr@2
|
40 |
* functions. Each CCTTokenTypeInfo object has a list of interfaces it supports,
|
williamr@2
|
41 |
* a list of TCTTokenTypeAttribute objects associated with it, and a label. Based
|
williamr@2
|
42 |
* on this, the client (or the user via a UI) can chose the required token type
|
williamr@2
|
43 |
* and load it via CCTTokenType::NewL().
|
williamr@2
|
44 |
*
|
williamr@2
|
45 |
* @since v7.0
|
williamr@2
|
46 |
*/
|
williamr@2
|
47 |
class CCTTokenTypeInfo : public CBase
|
williamr@2
|
48 |
{
|
williamr@2
|
49 |
public:
|
williamr@2
|
50 |
|
williamr@2
|
51 |
/**
|
williamr@2
|
52 |
* Lists all the CCTTokenTypeInfo objects that match the filter expression.
|
williamr@2
|
53 |
*
|
williamr@2
|
54 |
* This is the only way of creating CCTTokenTypeInfo objects.
|
williamr@2
|
55 |
*
|
williamr@2
|
56 |
* @param aTokenTypes An array to which the found token types will be appended.
|
williamr@2
|
57 |
* Ownership of the CCTTokenTypeInfo objects, whose pointers
|
williamr@2
|
58 |
* are held by the array, are transferred to the caller.
|
williamr@2
|
59 |
* @param aFilter An object that is used to filter tokens, by being offered each
|
williamr@2
|
60 |
* token in turn and declining the ones that are not required.
|
williamr@2
|
61 |
*/
|
williamr@2
|
62 |
IMPORT_C static void ListL(RCPointerArray<CCTTokenTypeInfo>& aTokenTypes,
|
williamr@2
|
63 |
const MCTTokenTypeFilter& aFilter);
|
williamr@2
|
64 |
|
williamr@2
|
65 |
/**
|
williamr@2
|
66 |
* Lists all the CCTTokenTypeInfo objects.
|
williamr@2
|
67 |
*
|
williamr@2
|
68 |
* This version does not take a filter, but returns all token types.
|
williamr@2
|
69 |
*
|
williamr@2
|
70 |
* @param aTokenTypes An array to which the found token types will be appended.
|
williamr@2
|
71 |
* Ownership of the CCTTokenTypeInfo objects, whose pointers
|
williamr@2
|
72 |
* are held by the array, are transferred to the caller.
|
williamr@2
|
73 |
*/
|
williamr@2
|
74 |
IMPORT_C static void ListL(RCPointerArray<CCTTokenTypeInfo>& aTokenTypes);
|
williamr@2
|
75 |
|
williamr@2
|
76 |
/**
|
williamr@2
|
77 |
* Destructor.
|
williamr@2
|
78 |
*
|
williamr@2
|
79 |
* Frees all resources owned by the object.
|
williamr@2
|
80 |
* @internalAll
|
williamr@2
|
81 |
*/
|
williamr@2
|
82 |
~CCTTokenTypeInfo();
|
williamr@2
|
83 |
|
williamr@2
|
84 |
/**
|
williamr@2
|
85 |
* Gets a list of all interfaces supported by this token type.
|
williamr@2
|
86 |
*
|
williamr@2
|
87 |
* @return A list of all the interfaces supported by this token type.
|
williamr@2
|
88 |
*/
|
williamr@2
|
89 |
IMPORT_C const RArray<TUid>& Interfaces() const;
|
williamr@2
|
90 |
|
williamr@2
|
91 |
/**
|
williamr@2
|
92 |
* Gets a list of all attributes of this token type.
|
williamr@2
|
93 |
*
|
williamr@2
|
94 |
* @return A list of all attributes of this token type.
|
williamr@2
|
95 |
*/
|
williamr@2
|
96 |
IMPORT_C const RArray<TCTTokenTypeAttribute>& Attributes() const;
|
williamr@2
|
97 |
|
williamr@2
|
98 |
/**
|
williamr@2
|
99 |
* Gets a human-readable name for the token type.
|
williamr@2
|
100 |
*
|
williamr@2
|
101 |
* @return A human-readable name for the token type.
|
williamr@2
|
102 |
*/
|
williamr@2
|
103 |
IMPORT_C const TDesC& Label() const;
|
williamr@2
|
104 |
|
williamr@2
|
105 |
/**
|
williamr@2
|
106 |
* Gets the UID of this token type.
|
williamr@2
|
107 |
*
|
williamr@2
|
108 |
* @return The UID of this token type.
|
williamr@2
|
109 |
*/
|
williamr@2
|
110 |
IMPORT_C TUid Type() const;
|
williamr@2
|
111 |
|
williamr@2
|
112 |
private:
|
williamr@2
|
113 |
/** Constructor */
|
williamr@2
|
114 |
CCTTokenTypeInfo(CImplementationInformation* aEcomImplementationInfo);
|
williamr@2
|
115 |
|
williamr@2
|
116 |
private:
|
williamr@2
|
117 |
CImplementationInformation* iEcomImplementationInfo;
|
williamr@2
|
118 |
RArray<TUid> iInterfaces;
|
williamr@2
|
119 |
RArray<TCTTokenTypeAttribute> iAttributes;
|
williamr@2
|
120 |
};
|
williamr@2
|
121 |
|
williamr@2
|
122 |
#endif // __CCTTOKENTYPEINFO_H__
|