@@ -785,8 +785,7 @@ ISC_TIMESTAMP_TZ_EX = record
785785 IPerformanceCounters_getObjectCountersPtr = function(this: IPerformanceCounters; index: Cardinal): Int64Ptr; cdecl;
786786 IPerformanceStats_getElapsedTimePtr = function(this: IPerformanceStats): QWord; cdecl;
787787 IPerformanceStats_getFetchedRecordsPtr = function(this: IPerformanceStats): QWord; cdecl;
788- IPerformanceStats_getPageCountersPtr = function(this: IPerformanceStats): IPerformanceCounters; cdecl;
789- IPerformanceStats_getTableCountersPtr = function(this: IPerformanceStats): IPerformanceCounters; cdecl;
788+ IPerformanceStats_getCountersPtr = function(this: IPerformanceStats; group: Cardinal): IPerformanceCounters; cdecl;
790789
791790 VersionedVTable = class
792791 version: NativeInt;
@@ -4112,26 +4111,25 @@ IPerformanceCountersImpl = class(IPerformanceCounters)
41124111 PerformanceStatsVTable = class(VersionedVTable)
41134112 getElapsedTime: IPerformanceStats_getElapsedTimePtr;
41144113 getFetchedRecords: IPerformanceStats_getFetchedRecordsPtr;
4115- getPageCounters: IPerformanceStats_getPageCountersPtr;
4116- getTableCounters: IPerformanceStats_getTableCountersPtr;
4114+ getCounters: IPerformanceStats_getCountersPtr;
41174115 end;
41184116
41194117 IPerformanceStats = class(IVersioned)
41204118 const VERSION = 2;
4119+ const COUNTER_GROUP_PAGES = Cardinal(0);
4120+ const COUNTER_GROUP_TABLES = Cardinal(1);
41214121
41224122 function getElapsedTime(): QWord;
41234123 function getFetchedRecords(): QWord;
4124- function getPageCounters(): IPerformanceCounters;
4125- function getTableCounters(): IPerformanceCounters;
4124+ function getCounters(group: Cardinal): IPerformanceCounters;
41264125 end;
41274126
41284127 IPerformanceStatsImpl = class(IPerformanceStats)
41294128 constructor create;
41304129
41314130 function getElapsedTime(): QWord; virtual; abstract;
41324131 function getFetchedRecords(): QWord; virtual; abstract;
4133- function getPageCounters(): IPerformanceCounters; virtual; abstract;
4134- function getTableCounters(): IPerformanceCounters; virtual; abstract;
4132+ function getCounters(group: Cardinal): IPerformanceCounters; virtual; abstract;
41354133 end;
41364134
41374135{$IFNDEF NO_FBCLIENT}
@@ -10253,14 +10251,9 @@ function IPerformanceStats.getFetchedRecords(): QWord;
1025310251 Result := PerformanceStatsVTable(vTable).getFetchedRecords(Self);
1025410252end;
1025510253
10256- function IPerformanceStats.getPageCounters( ): IPerformanceCounters;
10254+ function IPerformanceStats.getCounters(group: Cardinal ): IPerformanceCounters;
1025710255begin
10258- Result := PerformanceStatsVTable(vTable).getPageCounters(Self);
10259- end;
10260-
10261- function IPerformanceStats.getTableCounters(): IPerformanceCounters;
10262- begin
10263- Result := PerformanceStatsVTable(vTable).getTableCounters(Self);
10256+ Result := PerformanceStatsVTable(vTable).getCounters(Self, group);
1026410257end;
1026510258
1026610259var
@@ -17915,21 +17908,11 @@ function IPerformanceStatsImpl_getFetchedRecordsDispatcher(this: IPerformanceSta
1791517908 end
1791617909end;
1791717910
17918- function IPerformanceStatsImpl_getPageCountersDispatcher(this: IPerformanceStats): IPerformanceCounters; cdecl;
17919- begin
17920- Result := nil;
17921- try
17922- Result := IPerformanceStatsImpl(this).getPageCounters();
17923- except
17924- on e: Exception do FbException.catchException(nil, e);
17925- end
17926- end;
17927-
17928- function IPerformanceStatsImpl_getTableCountersDispatcher(this: IPerformanceStats): IPerformanceCounters; cdecl;
17911+ function IPerformanceStatsImpl_getCountersDispatcher(this: IPerformanceStats; group: Cardinal): IPerformanceCounters; cdecl;
1792917912begin
1793017913 Result := nil;
1793117914 try
17932- Result := IPerformanceStatsImpl(this).getTableCounters( );
17915+ Result := IPerformanceStatsImpl(this).getCounters(group );
1793317916 except
1793417917 on e: Exception do FbException.catchException(nil, e);
1793517918 end
@@ -19020,8 +19003,7 @@ initialization
1902019003 IPerformanceStatsImpl_vTable.version := 2;
1902119004 IPerformanceStatsImpl_vTable.getElapsedTime := @IPerformanceStatsImpl_getElapsedTimeDispatcher;
1902219005 IPerformanceStatsImpl_vTable.getFetchedRecords := @IPerformanceStatsImpl_getFetchedRecordsDispatcher;
19023- IPerformanceStatsImpl_vTable.getPageCounters := @IPerformanceStatsImpl_getPageCountersDispatcher;
19024- IPerformanceStatsImpl_vTable.getTableCounters := @IPerformanceStatsImpl_getTableCountersDispatcher;
19006+ IPerformanceStatsImpl_vTable.getCounters := @IPerformanceStatsImpl_getCountersDispatcher;
1902519007
1902619008finalization
1902719009 IVersionedImpl_vTable.destroy;
0 commit comments