- Timestamp:
- Aug 4, 2010, 1:49:55 PM (14 years ago)
- Location:
- Generics
- Files:
-
- 6 added
- 1 deleted
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
Generics
- Property svn:ignore
-
old new 1 1 lib 2 2 project1.exe 3 heaptrclog.trc 4 Test.exe
-
- Property svn:ignore
-
Generics/Test.lpi
r36 r37 40 40 </Item1> 41 41 </RequiredPackages> 42 <Units Count=" 13">42 <Units Count="24"> 43 43 <Unit0> 44 44 <Filename Value="Test.lpr"/> 45 45 <IsPartOfProject Value="True"/> 46 46 <UnitName Value="Test"/> 47 <IsVisibleTab Value="True"/>48 <EditorIndex Value="9"/>49 47 <WindowIndex Value="0"/> 50 48 <TopLine Value="1"/> 51 <CursorPos X="32" Y="10"/> 52 <UsageCount Value="22"/> 53 <Loaded Value="True"/> 49 <CursorPos X="72" Y="10"/> 50 <UsageCount Value="30"/> 54 51 </Unit0> 55 52 <Unit1> … … 61 58 <EditorIndex Value="0"/> 62 59 <WindowIndex Value="0"/> 63 <TopLine Value=" 1"/>64 <CursorPos X=" 1" Y="1"/>65 <UsageCount Value=" 22"/>60 <TopLine Value="52"/> 61 <CursorPos X="45" Y="65"/> 62 <UsageCount Value="30"/> 66 63 <Loaded Value="True"/> 67 64 <LoadedDesigner Value="True"/> 68 65 </Unit1> 69 66 <Unit2> 70 <Filename Value=" GenericList.pas"/>67 <Filename Value="units\GenericList.pas"/> 71 68 <IsPartOfProject Value="True"/> 72 69 <UnitName Value="GenericList"/> 73 <EditorIndex Value=" 1"/>74 <WindowIndex Value="0"/> 75 <TopLine Value=" 43"/>76 <CursorPos X=" 3" Y="17"/>77 <UsageCount Value=" 22"/>70 <EditorIndex Value="2"/> 71 <WindowIndex Value="0"/> 72 <TopLine Value="190"/> 73 <CursorPos X="20" Y="203"/> 74 <UsageCount Value="30"/> 78 75 <Loaded Value="True"/> 79 76 </Unit2> … … 81 78 <Filename Value="E:\Programy\Lazarus\fpc\2.4.0\source\rtl\win32\classes.pp"/> 82 79 <UnitName Value="Classes"/> 83 <WindowIndex Value="0"/> 84 <TopLine Value="1"/> 85 <CursorPos X="1" Y="1"/> 86 <UsageCount Value="10"/> 80 <EditorIndex Value="9"/> 81 <WindowIndex Value="0"/> 82 <TopLine Value="25"/> 83 <CursorPos X="15" Y="44"/> 84 <UsageCount Value="13"/> 85 <Loaded Value="True"/> 87 86 </Unit3> 88 87 <Unit4> 89 88 <Filename Value="E:\Programy\Lazarus\fpc\2.4.0\source\rtl\objpas\classes\classesh.inc"/> 90 <EditorIndex Value=" 3"/>91 <WindowIndex Value="0"/> 92 <TopLine Value=" 157"/>93 <CursorPos X="1 7" Y="207"/>94 <UsageCount Value="1 1"/>89 <EditorIndex Value="12"/> 90 <WindowIndex Value="0"/> 91 <TopLine Value="224"/> 92 <CursorPos X="15" Y="237"/> 93 <UsageCount Value="15"/> 95 94 <Loaded Value="True"/> 96 95 </Unit4> 97 96 <Unit5> 98 97 <Filename Value="E:\Programy\Lazarus\fpc\2.4.0\source\rtl\objpas\classes\lists.inc"/> 99 <EditorIndex Value=" 4"/>100 <WindowIndex Value="0"/> 101 <TopLine Value=" 225"/>102 <CursorPos X=" 28" Y="248"/>103 <UsageCount Value="1 1"/>98 <EditorIndex Value="14"/> 99 <WindowIndex Value="0"/> 100 <TopLine Value="658"/> 101 <CursorPos X="3" Y="661"/> 102 <UsageCount Value="15"/> 104 103 <Loaded Value="True"/> 105 104 </Unit5> 106 105 <Unit6> 107 106 <Filename Value="E:\Programy\Lazarus\fpc\2.4.0\source\rtl\inc\systemh.inc"/> 108 <EditorIndex Value=" 7"/>109 <WindowIndex Value="0"/> 110 <TopLine Value=" 890"/>111 <CursorPos X=" 10" Y="903"/>112 <UsageCount Value="1 1"/>107 <EditorIndex Value="16"/> 108 <WindowIndex Value="0"/> 109 <TopLine Value="505"/> 110 <CursorPos X="55" Y="512"/> 111 <UsageCount Value="15"/> 113 112 <Loaded Value="True"/> 114 113 </Unit6> 115 114 <Unit7> 116 115 <Filename Value="E:\Programy\Lazarus\fpc\2.4.0\source\rtl\i386\i386.inc"/> 117 <EditorIndex Value="8"/>118 116 <WindowIndex Value="0"/> 119 117 <TopLine Value="1049"/> 120 118 <CursorPos X="10" Y="1062"/> 121 <UsageCount Value="11"/> 122 <Loaded Value="True"/> 119 <UsageCount Value="12"/> 123 120 </Unit7> 124 121 <Unit8> 125 122 <Filename Value="E:\Programy\Lazarus\fpc\2.4.0\source\rtl\objpas\sysutils\sysutilh.inc"/> 126 <EditorIndex Value=" 6"/>127 <WindowIndex Value="0"/> 128 <TopLine Value=" 59"/>123 <EditorIndex Value="15"/> 124 <WindowIndex Value="0"/> 125 <TopLine Value="65"/> 129 126 <CursorPos X="19" Y="72"/> 130 <UsageCount Value="1 1"/>127 <UsageCount Value="15"/> 131 128 <Loaded Value="True"/> 132 129 </Unit8> 133 130 <Unit9> 134 131 <Filename Value="E:\Programy\Lazarus\fpc\2.4.0\source\rtl\inc\wstringh.inc"/> 135 <WindowIndex Value="0"/> 136 <TopLine Value="17"/> 137 <CursorPos X="16" Y="25"/> 138 <UsageCount Value="10"/> 132 <EditorIndex Value="4"/> 133 <WindowIndex Value="0"/> 134 <TopLine Value="6"/> 135 <CursorPos X="13" Y="34"/> 136 <UsageCount Value="12"/> 137 <Loaded Value="True"/> 139 138 </Unit9> 140 139 <Unit10> … … 143 142 <TopLine Value="965"/> 144 143 <CursorPos X="3" Y="969"/> 145 <UsageCount Value=" 10"/>144 <UsageCount Value="9"/> 146 145 </Unit10> 147 146 <Unit11> 148 147 <Filename Value="E:\Programy\Lazarus\fpc\2.4.0\source\rtl\objpas\rtlconst.inc"/> 149 <EditorIndex Value="5"/>150 148 <WindowIndex Value="0"/> 151 149 <TopLine Value="167"/> 152 150 <CursorPos X="3" Y="180"/> 153 <UsageCount Value="11"/> 154 <Loaded Value="True"/> 151 <UsageCount Value="12"/> 155 152 </Unit11> 156 153 <Unit12> 157 154 <Filename Value="E:\Programy\Lazarus\fpc\2.4.0\source\rtl\objpas\fgl.pp"/> 158 155 <UnitName Value="fgl"/> 159 <EditorIndex Value="2"/> 160 <WindowIndex Value="0"/> 161 <TopLine Value="42"/> 162 <CursorPos X="15" Y="43"/> 163 <UsageCount Value="10"/> 156 <IsVisibleTab Value="True"/> 157 <EditorIndex Value="11"/> 158 <WindowIndex Value="0"/> 159 <TopLine Value="57"/> 160 <CursorPos X="15" Y="70"/> 161 <UsageCount Value="14"/> 164 162 <Loaded Value="True"/> 165 163 </Unit12> 164 <Unit13> 165 <Filename Value="E:\Programy\Lazarus\fpc\2.4.0\source\rtl\i386\fastmove.inc"/> 166 <WindowIndex Value="0"/> 167 <TopLine Value="785"/> 168 <CursorPos X="11" Y="834"/> 169 <UsageCount Value="11"/> 170 </Unit13> 171 <Unit14> 172 <Filename Value="E:\Programy\Lazarus\lcl\include\customform.inc"/> 173 <EditorIndex Value="1"/> 174 <WindowIndex Value="0"/> 175 <TopLine Value="878"/> 176 <CursorPos X="30" Y="910"/> 177 <UsageCount Value="14"/> 178 <Loaded Value="True"/> 179 </Unit14> 180 <Unit15> 181 <Filename Value="units\GenericThreadedItem.pas"/> 182 <IsPartOfProject Value="True"/> 183 <UnitName Value="GenericThreadedItem"/> 184 <WindowIndex Value="0"/> 185 <TopLine Value="1"/> 186 <CursorPos X="1" Y="1"/> 187 <UsageCount Value="28"/> 188 </Unit15> 189 <Unit16> 190 <Filename Value="units\GenericSet.pas"/> 191 <IsPartOfProject Value="True"/> 192 <UnitName Value="GenericSet"/> 193 <WindowIndex Value="0"/> 194 <TopLine Value="1"/> 195 <CursorPos X="5" Y="12"/> 196 <UsageCount Value="28"/> 197 </Unit16> 198 <Unit17> 199 <Filename Value="units\GenericStream.pas"/> 200 <IsPartOfProject Value="True"/> 201 <UnitName Value="GenericStream"/> 202 <EditorIndex Value="10"/> 203 <WindowIndex Value="0"/> 204 <TopLine Value="1"/> 205 <CursorPos X="11" Y="11"/> 206 <UsageCount Value="28"/> 207 <Loaded Value="True"/> 208 </Unit17> 209 <Unit18> 210 <Filename Value="E:\Programy\Lazarus\fpc\2.4.0\source\rtl\objpas\types.pp"/> 211 <UnitName Value="types"/> 212 <EditorIndex Value="13"/> 213 <WindowIndex Value="0"/> 214 <TopLine Value="111"/> 215 <CursorPos X="3" Y="124"/> 216 <UsageCount Value="13"/> 217 <Loaded Value="True"/> 218 </Unit18> 219 <Unit19> 220 <Filename Value="E:\Programy\Lazarus\fpc\2.4.0\source\rtl\win\sysosh.inc"/> 221 <EditorIndex Value="8"/> 222 <WindowIndex Value="0"/> 223 <TopLine Value="53"/> 224 <CursorPos X="3" Y="33"/> 225 <UsageCount Value="13"/> 226 <Loaded Value="True"/> 227 </Unit19> 228 <Unit20> 229 <Filename Value="E:\Programy\Lazarus\fpc\2.4.0\source\packages\fcl-base\src\syncobjs.pp"/> 230 <UnitName Value="syncobjs"/> 231 <EditorIndex Value="5"/> 232 <WindowIndex Value="0"/> 233 <TopLine Value="123"/> 234 <CursorPos X="16" Y="126"/> 235 <UsageCount Value="13"/> 236 <Loaded Value="True"/> 237 </Unit20> 238 <Unit21> 239 <Filename Value="E:\Programy\Lazarus\fpc\2.4.0\source\rtl\inc\threadh.inc"/> 240 <EditorIndex Value="6"/> 241 <WindowIndex Value="0"/> 242 <TopLine Value="57"/> 243 <CursorPos X="5" Y="70"/> 244 <UsageCount Value="13"/> 245 <Loaded Value="True"/> 246 </Unit21> 247 <Unit22> 248 <Filename Value="E:\Programy\Lazarus\fpc\2.4.0\source\rtl\inc\thread.inc"/> 249 <EditorIndex Value="7"/> 250 <WindowIndex Value="0"/> 251 <TopLine Value="187"/> 252 <CursorPos X="22" Y="190"/> 253 <UsageCount Value="13"/> 254 <Loaded Value="True"/> 255 </Unit22> 256 <Unit23> 257 <Filename Value="units\GenericTree.pas"/> 258 <IsPartOfProject Value="True"/> 259 <UnitName Value="GenericTree"/> 260 <EditorIndex Value="3"/> 261 <WindowIndex Value="0"/> 262 <TopLine Value="1"/> 263 <CursorPos X="35" Y="11"/> 264 <UsageCount Value="22"/> 265 <Loaded Value="True"/> 266 </Unit23> 166 267 </Units> 167 <JumpHistory Count=" 22" HistoryIndex="21">268 <JumpHistory Count="30" HistoryIndex="29"> 168 269 <Position1> 169 <Filename Value=" GenericList.pas"/>170 <Caret Line=" 39" Column="42" TopLine="25"/>270 <Filename Value="units\GenericList.pas"/> 271 <Caret Line="48" Column="1" TopLine="28"/> 171 272 </Position1> 172 273 <Position2> 173 <Filename Value=" GenericList.pas"/>174 <Caret Line=" 15" Column="1" TopLine="10"/>274 <Filename Value="units\GenericList.pas"/> 275 <Caret Line="32" Column="47" TopLine="19"/> 175 276 </Position2> 176 277 <Position3> 177 <Filename Value=" GenericList.pas"/>178 <Caret Line=" 37" Column="1" TopLine="20"/>278 <Filename Value="units\GenericList.pas"/> 279 <Caret Line="41" Column="1" TopLine="28"/> 179 280 </Position3> 180 281 <Position4> 181 <Filename Value=" GenericList.pas"/>182 <Caret Line=" 36" Column="49" TopLine="23"/>282 <Filename Value="units\GenericList.pas"/> 283 <Caret Line="128" Column="1" TopLine="108"/> 183 284 </Position4> 184 285 <Position5> 185 <Filename Value=" GenericList.pas"/>186 <Caret Line=" 35" Column="50" TopLine="23"/>286 <Filename Value="units\GenericList.pas"/> 287 <Caret Line="48" Column="23" TopLine="35"/> 187 288 </Position5> 188 289 <Position6> 189 <Filename Value=" GenericList.pas"/>190 <Caret Line="5 3" Column="63" TopLine="48"/>290 <Filename Value="units\GenericList.pas"/> 291 <Caret Line="57" Column="55" TopLine="38"/> 191 292 </Position6> 192 293 <Position7> 193 <Filename Value=" GenericList.pas"/>194 <Caret Line=" 8" Column="23" TopLine="2"/>294 <Filename Value="units\GenericList.pas"/> 295 <Caret Line="305" Column="1" TopLine="280"/> 195 296 </Position7> 196 297 <Position8> 197 <Filename Value=" E:\Programy\Lazarus\fpc\2.4.0\source\rtl\objpas\fgl.pp"/>198 <Caret Line=" 112" Column="34" TopLine="91"/>298 <Filename Value="units\GenericList.pas"/> 299 <Caret Line="272" Column="1" TopLine="259"/> 199 300 </Position8> 200 301 <Position9> 201 <Filename Value=" GenericList.pas"/>202 <Caret Line="4 6" Column="22" TopLine="23"/>302 <Filename Value="units\GenericList.pas"/> 303 <Caret Line="47" Column="26" TopLine="34"/> 203 304 </Position9> 204 305 <Position10> 205 <Filename Value=" GenericList.pas"/>206 <Caret Line=" 198" Column="3" TopLine="196"/>306 <Filename Value="units\GenericList.pas"/> 307 <Caret Line="50" Column="64" TopLine="43"/> 207 308 </Position10> 208 309 <Position11> 209 <Filename Value=" E:\Programy\Lazarus\fpc\2.4.0\source\rtl\objpas\fgl.pp"/>210 <Caret Line=" 701" Column="25" TopLine="698"/>310 <Filename Value="units\GenericList.pas"/> 311 <Caret Line="64" Column="23" TopLine="49"/> 211 312 </Position11> 212 313 <Position12> 213 <Filename Value=" E:\Programy\Lazarus\fpc\2.4.0\source\rtl\objpas\classes\lists.inc"/>214 <Caret Line=" 279" Column="8" TopLine="276"/>314 <Filename Value="units\GenericList.pas"/> 315 <Caret Line="302" Column="20" TopLine="300"/> 215 316 </Position12> 216 317 <Position13> 217 <Filename Value=" GenericList.pas"/>218 <Caret Line=" 32" Column="65" TopLine="27"/>318 <Filename Value="units\GenericList.pas"/> 319 <Caret Line="236" Column="34" TopLine="231"/> 219 320 </Position13> 220 321 <Position14> 221 <Filename Value=" GenericList.pas"/>222 <Caret Line=" 117" Column="50" TopLine="104"/>322 <Filename Value="units\GenericList.pas"/> 323 <Caret Line="233" Column="7" TopLine="220"/> 223 324 </Position14> 224 325 <Position15> 225 <Filename Value=" GenericList.pas"/>226 <Caret Line=" 141" Column="16" TopLine="120"/>326 <Filename Value="units\GenericList.pas"/> 327 <Caret Line="224" Column="5" TopLine="222"/> 227 328 </Position15> 228 329 <Position16> 229 <Filename Value=" GenericList.pas"/>230 <Caret Line=" 133" Column="19" TopLine="120"/>330 <Filename Value="units\GenericList.pas"/> 331 <Caret Line="238" Column="16" TopLine="222"/> 231 332 </Position16> 232 333 <Position17> 233 <Filename Value=" E:\Programy\Lazarus\fpc\2.4.0\source\rtl\objpas\fgl.pp"/>234 <Caret Line=" 89" Column="17" TopLine="78"/>334 <Filename Value="units\GenericList.pas"/> 335 <Caret Line="29" Column="16" TopLine="13"/> 235 336 </Position17> 236 337 <Position18> 237 <Filename Value=" E:\Programy\Lazarus\fpc\2.4.0\source\rtl\objpas\fgl.pp"/>238 <Caret Line=" 94" Column="29" TopLine="78"/>338 <Filename Value="units\GenericList.pas"/> 339 <Caret Line="30" Column="27" TopLine="17"/> 239 340 </Position18> 240 341 <Position19> 241 <Filename Value=" E:\Programy\Lazarus\fpc\2.4.0\source\rtl\objpas\fgl.pp"/>242 <Caret Line=" 112" Column="41" TopLine="99"/>342 <Filename Value="units\GenericList.pas"/> 343 <Caret Line="33" Column="55" TopLine="20"/> 243 344 </Position19> 244 345 <Position20> 245 <Filename Value=" E:\Programy\Lazarus\fpc\2.4.0\source\rtl\objpas\fgl.pp"/>246 <Caret Line=" 272" Column="15" TopLine="258"/>346 <Filename Value="units\GenericList.pas"/> 347 <Caret Line="47" Column="42" TopLine="38"/> 247 348 </Position20> 248 349 <Position21> 249 <Filename Value=" E:\Programy\Lazarus\fpc\2.4.0\source\rtl\objpas\fgl.pp"/>250 <Caret Line=" 560" Column="73" TopLine="547"/>350 <Filename Value="units\GenericList.pas"/> 351 <Caret Line="244" Column="5" TopLine="227"/> 251 352 </Position21> 252 353 <Position22> 253 <Filename Value=" GenericList.pas"/>254 <Caret Line=" 47" Column="32" TopLine="34"/>354 <Filename Value="units\GenericList.pas"/> 355 <Caret Line="247" Column="1" TopLine="234"/> 255 356 </Position22> 357 <Position23> 358 <Filename Value="units\GenericList.pas"/> 359 <Caret Line="67" Column="1" TopLine="54"/> 360 </Position23> 361 <Position24> 362 <Filename Value="units\GenericList.pas"/> 363 <Caret Line="305" Column="16" TopLine="289"/> 364 </Position24> 365 <Position25> 366 <Filename Value="units\GenericList.pas"/> 367 <Caret Line="302" Column="17" TopLine="289"/> 368 </Position25> 369 <Position26> 370 <Filename Value="units\GenericList.pas"/> 371 <Caret Line="309" Column="5" TopLine="292"/> 372 </Position26> 373 <Position27> 374 <Filename Value="units\GenericList.pas"/> 375 <Caret Line="338" Column="16" TopLine="322"/> 376 </Position27> 377 <Position28> 378 <Filename Value="UMainForm.pas"/> 379 <Caret Line="9" Column="23" TopLine="1"/> 380 </Position28> 381 <Position29> 382 <Filename Value="UMainForm.pas"/> 383 <Caret Line="65" Column="45" TopLine="52"/> 384 </Position29> 385 <Position30> 386 <Filename Value="units\GenericList.pas"/> 387 <Caret Line="342" Column="1" TopLine="329"/> 388 </Position30> 256 389 </JumpHistory> 257 390 </ProjectOptions> … … 264 397 <SearchPaths> 265 398 <IncludeFiles Value="$(ProjOutDir)\"/> 399 <OtherUnitFiles Value="units\"/> 266 400 <UnitOutputDirectory Value="lib\$(TargetCPU)-$(TargetOS)"/> 267 401 </SearchPaths> 402 <CodeGeneration> 403 <Checks> 404 <IOChecks Value="True"/> 405 <RangeChecks Value="True"/> 406 <OverflowChecks Value="True"/> 407 <StackChecks Value="True"/> 408 </Checks> 409 </CodeGeneration> 268 410 <Linking> 411 <Debugging> 412 <GenerateDebugInfo Value="True"/> 413 <GenerateDwarf Value="True"/> 414 <UseHeaptrc Value="True"/> 415 </Debugging> 269 416 <Options> 270 417 <Win32> … … 274 421 </Linking> 275 422 <Other> 423 <CompilerMessages> 424 <UseMsgFile Value="True"/> 425 </CompilerMessages> 276 426 <CompilerPath Value="$(CompPath)"/> 277 427 </Other> -
Generics/Test.lpr
r36 r37 8 8 {$ENDIF}{$ENDIF} 9 9 Interfaces, // this includes the LCL widgetset 10 Forms, UMainForm, GenericList11 { you can add units after this };10 Forms, UMainForm, SysUtils, GenericList, GenericThreadedItem, GenericSet, 11 GenericStream, GenericTree; 12 12 13 13 {$R *.res} 14 14 15 15 begin 16 // Heap trace 17 DeleteFile(ExtractFilePath(ParamStr(0)) + 'heaptrclog.trc'); 18 SetHeapTraceOutput(ExtractFilePath(ParamStr(0)) + 'heaptrclog.trc'); 19 16 20 Application.Initialize; 17 21 Application.CreateForm(TMainForm, MainForm); -
Generics/UMainForm.lfm
r36 r37 8 8 ClientWidth = 319 9 9 OnCreate = FormCreate 10 OnDestroy = FormDestroy 10 11 OnShow = FormShow 11 12 LCLVersion = '0.9.29' -
Generics/UMainForm.pas
r36 r37 7 7 uses 8 8 Classes, SysUtils, FileUtil, Forms, Controls, Graphics, Dialogs, StdCtrls, 9 GenericList ;9 GenericList, GenericSet; 10 10 11 11 type 12 13 { TMyObject } 14 15 TMyObject = class 16 Name: string; 17 constructor Create(AName: string); 18 end; 19 20 TMyObjectList = specialize TGList<Integer, TMyObject>; 21 12 22 { TMainForm } 13 23 … … 15 25 Memo1: TMemo; 16 26 procedure FormCreate(Sender: TObject); 27 procedure FormDestroy(Sender: TObject); 17 28 procedure FormShow(Sender: TObject); 18 29 private 19 30 { private declarations } 20 31 public 21 IntegerList: TIntegerList; 22 StringList: TStringList; 32 IntegerList: TIntegerGList; 33 StringList: TStringGList; 34 MyObjectList: TMyObjectList; 23 35 end; 24 36 … … 34 46 procedure TMainForm.FormCreate(Sender: TObject); 35 47 begin 36 IntegerList := TIntegerList.Create; 37 StringList := TStringList.Create; 48 IntegerList := TIntegerGList.Create; 49 StringList := TStringGList.Create; 50 MyObjectList := TMyObjectList.Create; 51 end; 52 53 procedure TMainForm.FormDestroy(Sender: TObject); 54 begin 55 IntegerList.Destroy; 56 StringList.Destroy; 57 MyObjectList.Destroy; 38 58 end; 39 59 … … 53 73 IntegerList.Add(12121); 54 74 IntegerList.Add(5); 75 76 for I := 0 to StringList.Count - 1 do 77 Memo1.Lines.Add(StringList[I]); 78 55 79 StringList.Add('One'); 56 80 StringList.Add('Two'); 57 81 StringList.Add('Three'); 58 82 59 for I := 0 to StringList.Count - 1 do60 Memo1.Lines.Add(StringList[I]);61 62 83 IntegerList.Sort(@IntegerListCompare); 63 84 for I := 0 to IntegerList.Count - 1 do 64 85 Memo1.Lines.Add(IntToStr(IntegerList[I])); 86 87 MyObjectList.Add(TMyObject.Create('Object 1')); 88 MyObjectList.Add(TMyObject.Create('Object 2')); 89 MyObjectList.Add(TMyObject.Create('Object 3')); 90 91 for I := 0 to MyObjectList.Count - 1 do 92 Memo1.Lines.Add(MyObjectList[I].Name); 93 end; 94 95 { TObjectItem } 96 97 constructor TMyObject.Create(AName: string); 98 begin 99 Name := AName; 65 100 end; 66 101
Note:
See TracChangeset
for help on using the changeset viewer.