// Copyright Epic Games, Inc. All Rights Reserved. #pragma warning disable CA1822 // Mark members as static namespace EpicGames.Core { #if !__SCOPEPROFILER_AVAILABLE__ #pragma warning disable IDE0060 // Remove unused parameter /// /// A stub/no-op scope-profiler API that can be replaced by another implementation to record execution of /// instrumented scopes. /// public class ScopeProfiler { /// /// Static instance of the profiler /// public static ScopeProfiler Instance { get; } = new ScopeProfiler(); /// /// /// /// /// /// public void InitializeAndStart(string programName, string hostAddress, int maxThreadCount) { } /// /// /// public void StopAndShutdown() { } /// /// Start a stacked scope. Must start and end on the same thread /// /// /// public void StartScope(string name, bool bIsStall) { } /// /// End a stacked scope. Must start and end on the same thread. /// public void EndScope() { } /// /// Record an un-stacked time span at a specified time. /// /// /// /// /// /// /// start time for the span (use FastTime()) /// end time for the span (use FastTime()) public void AddSpanAtTime(string name, ulong id, bool bStall, uint beginThreadId, uint endThreadId, ulong startTime, ulong endTime) { } /// /// Record a value against a particular name, to be plotted over time /// /// /// public void Plot(string name, double value) { } /// /// Generate a timestamp value for the current moment. /// /// public ulong FastTime() { return 0; } /// /// Retrieve the profiler's identifier for the current thread /// /// public uint GetCurrentThreadId() { return 0; } } #pragma warning restore IDE0060 // Remove unused parameter #endif }