If you want to have such functionality, then you must implement it yourself.
Since Delphi 2010 it is could possibly even take the new
RTTI support.
since Delphi 2006 / Turbo Delphi
Delphi-Quellcode:
TPerfFormattedData_PerfOS_Processor = record
C1TransitionsPerSec: String;
C2TransitionsPerSec: String;
...
Timestamp_Sys100NS: String;
private
function GetProp(i: Integer): String;
public
property Prop[i: Integer]: String read GetProp;
end;
or
Delphi-Quellcode:
TPerfFormattedData_PerfOS_Processor = record
C1TransitionsPerSec: String;
C2TransitionsPerSec: String;
...
Timestamp_Sys100NS: String;
end;
TPerfFormattedData_PerfOS_Processor_Helper = record helper for TPerfFormattedData_PerfOS_Processor
private
function GetProp(i: Integer): String;
public
property Prop[i: Integer]: String read GetProp;
end;
Delphi-Quellcode:
function TPerfFormattedData_PerfOS_Processor
{_Helper}.GetProp(i: Integer):
String;
begin
case i
of
0: Result := C1TransitionsPerSec;
1: Result := C2TransitionsPerSec;
...
23: Result := Timestamp_Sys100NS;
else Raise Exception.Create('
invalid index');
end;
end;