|
1 /* |
|
2 * Copyright (c) 2002-2004 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of "Eclipse Public License v1.0" |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: Heap-allocated pointer array |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 // INCLUDE FILES |
|
21 #include "xnpointerarray.h" |
|
22 #include "xnpanic.h" |
|
23 |
|
24 // EXTERNAL DATA STRUCTURES |
|
25 //extern ?external_data; |
|
26 |
|
27 // EXTERNAL FUNCTION PROTOTYPES |
|
28 //extern ?external_function( ?arg_type,?arg_type ); |
|
29 |
|
30 // CONSTANTS |
|
31 //const ?type ?constant_var = ?constant; |
|
32 |
|
33 // MACROS |
|
34 //#define ?macro ?macro_def |
|
35 |
|
36 // LOCAL CONSTANTS AND MACROS |
|
37 //const ?type ?constant_var = ?constant; |
|
38 //#define ?macro_name ?macro_def |
|
39 |
|
40 // MODULE DATA STRUCTURES |
|
41 //enum ?declaration |
|
42 //typedef ?declaration |
|
43 |
|
44 // LOCAL FUNCTION PROTOTYPES |
|
45 //?type ?function_name( ?arg_type, ?arg_type ); |
|
46 |
|
47 // FORWARD DECLARATIONS |
|
48 //class ?FORWARD_CLASSNAME; |
|
49 |
|
50 // ============================= LOCAL FUNCTIONS =============================== |
|
51 |
|
52 // ----------------------------------------------------------------------------- |
|
53 // ?function_name ?description. |
|
54 // ?description |
|
55 // Returns: ?value_1: ?description |
|
56 // ?value_n: ?description_line1 |
|
57 // ?description_line2 |
|
58 // ----------------------------------------------------------------------------- |
|
59 // |
|
60 //?type ?function_name( |
|
61 // ?arg_type arg, // ?description |
|
62 // ?arg_type arg) // ?description |
|
63 // { |
|
64 |
|
65 // ?code // ?comment |
|
66 |
|
67 // ?comment |
|
68 // ?code |
|
69 // } |
|
70 |
|
71 |
|
72 // ============================ MEMBER FUNCTIONS =============================== |
|
73 |
|
74 // ----------------------------------------------------------------------------- |
|
75 // CXnPointerArray::CXnPointerArray |
|
76 // C++ default constructor can NOT contain any code, that |
|
77 // might leave. |
|
78 // ----------------------------------------------------------------------------- |
|
79 // |
|
80 CXnPointerArray::CXnPointerArray() |
|
81 { |
|
82 } |
|
83 |
|
84 // ----------------------------------------------------------------------------- |
|
85 // CXnPointerArray::ConstructL |
|
86 // Symbian 2nd phase constructor can leave. |
|
87 // ----------------------------------------------------------------------------- |
|
88 // |
|
89 void CXnPointerArray::ConstructL() |
|
90 { |
|
91 } |
|
92 |
|
93 // ----------------------------------------------------------------------------- |
|
94 // CXnPointerArray::NewL |
|
95 // Two-phased constructor. |
|
96 // ----------------------------------------------------------------------------- |
|
97 // |
|
98 EXPORT_C CXnPointerArray* CXnPointerArray::NewL() |
|
99 { |
|
100 CXnPointerArray* self = new( ELeave ) CXnPointerArray; |
|
101 |
|
102 CleanupStack::PushL( self ); |
|
103 self->ConstructL(); |
|
104 CleanupStack::Pop(); |
|
105 |
|
106 return self; |
|
107 } |
|
108 |
|
109 |
|
110 // Destructor |
|
111 CXnPointerArray::~CXnPointerArray() |
|
112 { |
|
113 iContainer.Reset(); |
|
114 } |
|
115 // ----------------------------------------------------------------------------- |
|
116 // CXnPointerArray::Container |
|
117 // Get the underlying container |
|
118 // ----------------------------------------------------------------------------- |
|
119 EXPORT_C RPointerArray<CBase>& CXnPointerArray::Container() |
|
120 { |
|
121 return iContainer; |
|
122 } |
|
123 |
|
124 // ========================== OTHER EXPORTED FUNCTIONS ========================= |
|
125 |
|
126 // ----------------------------------------------------------------------------- |
|
127 // ?function_name implements... |
|
128 // ?implementation_description. |
|
129 // Returns: ?value_1: ?description |
|
130 // ?value_n: ?description |
|
131 // ?description |
|
132 // ----------------------------------------------------------------------------- |
|
133 // |
|
134 //?type ?function_name( |
|
135 // ?arg_type arg, // ?description |
|
136 // ?arg_type arg ) // ?description |
|
137 // { |
|
138 |
|
139 // ?code |
|
140 |
|
141 // } |
|
142 |
|
143 |
|
144 // End of File |