author | William Roberts <williamr@symbian.org> |
Wed, 31 Mar 2010 12:33:34 +0100 | |
branch | Symbian3 |
changeset 4 | 837f303aceeb |
parent 2 | 2fe1408b6811 |
permissions | -rw-r--r-- |
williamr@2 | 1 |
// Copyright (c) 1997-2009 Nokia Corporation and/or its subsidiary(-ies). |
williamr@2 | 2 |
// All rights reserved. |
williamr@2 | 3 |
// This component and the accompanying materials are made available |
williamr@4 | 4 |
// under the terms of "Eclipse Public License v1.0" |
williamr@2 | 5 |
// which accompanies this distribution, and is available |
williamr@4 | 6 |
// at the URL "http://www.eclipse.org/legal/epl-v10.html". |
williamr@2 | 7 |
// |
williamr@2 | 8 |
// Initial Contributors: |
williamr@2 | 9 |
// Nokia Corporation - initial contribution. |
williamr@2 | 10 |
// |
williamr@2 | 11 |
// Contributors: |
williamr@2 | 12 |
// |
williamr@2 | 13 |
// Description: |
williamr@2 | 14 |
// Started by DavidW, March 1996 |
williamr@2 | 15 |
// Mixin descriptor array |
williamr@2 | 16 |
// |
williamr@2 | 17 |
// |
williamr@2 | 18 |
|
williamr@2 | 19 |
#if !defined(__BAMDESCA_H__) |
williamr@2 | 20 |
#define __BAMDESCA_H__ |
williamr@2 | 21 |
|
williamr@2 | 22 |
#if !defined(__E32STD_H__) |
williamr@2 | 23 |
#include <e32std.h> |
williamr@2 | 24 |
#endif |
williamr@2 | 25 |
|
williamr@2 | 26 |
|
williamr@2 | 27 |
|
williamr@2 | 28 |
class MDesC8Array |
williamr@2 | 29 |
/** |
williamr@2 | 30 |
Interface class for 8 bit descriptor arrays. |
williamr@2 | 31 |
It should be inherited by classes which implement this protocol. |
williamr@2 | 32 |
|
williamr@2 | 33 |
This protocol is implemented by class CDesC8Array and the concrete class CPtrC8Array. |
williamr@2 | 34 |
@publishedAll |
williamr@2 | 35 |
@released |
williamr@2 | 36 |
*/ |
williamr@2 | 37 |
{ |
williamr@2 | 38 |
public: |
williamr@2 | 39 |
/** Destructor. */ |
williamr@2 | 40 |
virtual ~MDesC8Array() {} |
williamr@2 | 41 |
/** Requirements |
williamr@2 | 42 |
|
williamr@2 | 43 |
Returns the number of descriptor elements in a descriptor array. |
williamr@2 | 44 |
|
williamr@2 | 45 |
@return The number of descriptor elements in a descriptor array. */ |
williamr@2 | 46 |
virtual TInt MdcaCount() const =0; |
williamr@2 | 47 |
|
williamr@2 | 48 |
/** Requirements |
williamr@2 | 49 |
|
williamr@2 | 50 |
Indexes into a descriptor array. |
williamr@2 | 51 |
|
williamr@2 | 52 |
@param aIndex The position of the descriptor element within a descriptor array. |
williamr@2 | 53 |
The position is relative to zero; i.e. zero implies the first descriptor element |
williamr@2 | 54 |
in a descriptor array. |
williamr@2 | 55 |
@return An 8 bit non-modifiable pointer descriptor representing the descriptor |
williamr@2 | 56 |
element located at position aIndex within a descriptor array. */ |
williamr@2 | 57 |
virtual TPtrC8 MdcaPoint(TInt aIndex) const =0; |
williamr@2 | 58 |
}; |
williamr@2 | 59 |
|
williamr@2 | 60 |
|
williamr@2 | 61 |
class MDesC16Array |
williamr@2 | 62 |
/** |
williamr@2 | 63 |
Interface class for 16 bit descriptor arrays. It should be inherited by classes |
williamr@2 | 64 |
which implement this protocol. |
williamr@2 | 65 |
This protocol is implemented by class CDesC16Array and the concrete class |
williamr@2 | 66 |
CPtrC16Array. |
williamr@2 | 67 |
@publishedAll |
williamr@2 | 68 |
@released |
williamr@2 | 69 |
*/ |
williamr@2 | 70 |
{ |
williamr@2 | 71 |
public: |
williamr@2 | 72 |
/** Destructor. */ |
williamr@2 | 73 |
virtual ~MDesC16Array() {} |
williamr@2 | 74 |
|
williamr@2 | 75 |
/** Requirements |
williamr@2 | 76 |
|
williamr@2 | 77 |
Returns the number of descriptor elements in a descriptor array. |
williamr@2 | 78 |
|
williamr@2 | 79 |
@return The number of descriptor elements in a descriptor array. */ |
williamr@2 | 80 |
virtual TInt MdcaCount() const =0; |
williamr@2 | 81 |
/** Requirements |
williamr@2 | 82 |
|
williamr@2 | 83 |
Indexes into a descriptor array. |
williamr@2 | 84 |
|
williamr@2 | 85 |
@param aIndex The position of the descriptor element within a descriptor array. |
williamr@2 | 86 |
The position is relative to zero; i.e. zero implies the first descriptor element |
williamr@2 | 87 |
in a descriptor array. |
williamr@2 | 88 |
@return A 16 bit non-modifiable pointer descriptor representing the descriptor |
williamr@2 | 89 |
element located at position aIndex within a descriptor array. */ |
williamr@2 | 90 |
virtual TPtrC16 MdcaPoint(TInt aIndex) const =0; |
williamr@2 | 91 |
}; |
williamr@2 | 92 |
|
williamr@2 | 93 |
|
williamr@2 | 94 |
// The definitions below are macros rather than typedefs to avoid generating |
williamr@2 | 95 |
// warning C4097 every time the generic mixin class is used in a class |
williamr@2 | 96 |
// definition. |
williamr@2 | 97 |
|
williamr@2 | 98 |
#if defined(_UNICODE) |
williamr@2 | 99 |
/** |
williamr@2 | 100 |
Build independent interface class for descriptor arrays. |
williamr@2 | 101 |
|
williamr@2 | 102 |
A 16 bit build variant is generated for a Unicode build and an 8 bit build |
williamr@2 | 103 |
variant generated for a non-Unicode build. |
williamr@2 | 104 |
|
williamr@2 | 105 |
This build independent type should always be used unless an explicit 8 bit |
williamr@2 | 106 |
or 16 bit build variant is required. |
williamr@2 | 107 |
|
williamr@2 | 108 |
@see MDesC16Array |
williamr@2 | 109 |
@see MDesC8Array |
williamr@2 | 110 |
@publishedAll |
williamr@2 | 111 |
@released |
williamr@2 | 112 |
*/ |
williamr@2 | 113 |
#define MDesCArray MDesC16Array |
williamr@2 | 114 |
//typedef MDesC16Array MDesCArray; |
williamr@2 | 115 |
#else |
williamr@2 | 116 |
/** |
williamr@2 | 117 |
Build independent interface class for descriptor arrays. |
williamr@2 | 118 |
|
williamr@2 | 119 |
A 16 bit build variant is generated for a Unicode build and an 8 bit build |
williamr@2 | 120 |
variant generated for a non-Unicode build. |
williamr@2 | 121 |
|
williamr@2 | 122 |
This build independent type should always be used unless an explicit 8 bit |
williamr@2 | 123 |
or 16 bit build variant is required. |
williamr@2 | 124 |
|
williamr@2 | 125 |
@see MDesC16Array |
williamr@2 | 126 |
@see MDesC8Array |
williamr@2 | 127 |
@publishedAll |
williamr@2 | 128 |
@released |
williamr@2 | 129 |
*/ |
williamr@2 | 130 |
#define MDesCArray MDesC8Array |
williamr@2 | 131 |
//typedef MDesC8Array MDesCArray; |
williamr@2 | 132 |
#endif |
williamr@2 | 133 |
|
williamr@2 | 134 |
|
williamr@2 | 135 |
#endif // __BAMDESCA_H__ |
williamr@4 | 136 |