|
@@ -183,8 +183,16 @@ end;
|
|
|
|
|
|
class function TDebugger.Enter(aOwner : TObject; const aFunctionName: string) : IDebugMethodEnter;
|
|
class function TDebugger.Enter(aOwner : TObject; const aFunctionName: string) : IDebugMethodEnter;
|
|
begin
|
|
begin
|
|
- fLogger.Debug(Format('[ENTER] >> %s.%s',[aOwner.ClassName,aFunctionName]));
|
|
|
|
- Result := TDebugMethodEnter.Create(fLogger,Format('%s.%s',[aOwner.ClassName,aFunctionName]));
|
|
|
|
|
|
+ if aOwner <> nil then
|
|
|
|
+ begin
|
|
|
|
+ fLogger.Debug(Format('[ENTER] >> %s.%s',[aOwner.ClassName,aFunctionName]));
|
|
|
|
+ Result := TDebugMethodEnter.Create(fLogger,Format('%s.%s',[aOwner.ClassName,aFunctionName]));
|
|
|
|
+ end
|
|
|
|
+ else
|
|
|
|
+ begin
|
|
|
|
+ fLogger.Debug(Format('[ENTER] >> %s',[aFunctionName]));
|
|
|
|
+ Result := TDebugMethodEnter.Create(fLogger,aFunctionName);
|
|
|
|
+ end;
|
|
end;
|
|
end;
|
|
|
|
|
|
class function TDebugger.NewChrono(aStarted : Boolean) : IChronometer;
|
|
class function TDebugger.NewChrono(aStarted : Boolean) : IChronometer;
|