dotTrace 2016.3 Help

API Reference

PerformanceProfiler Class Properties

ItemTypeDescription
CanDetach bool Indicates whether detach operation is possible.
IsActive bool Indicates whether profiler is active (either attached or the application is executed under profiler). Check this property only ONCE. Your method must do nothing (throw exceptions, etc.) in case IsActive is false.

PerformanceProfiler Class Methods

ItemDescription
Begin() Creates a blank snapshot.
Start() Starts collecting performance data.
Stop() Stops collecting performance data. Current data will persist in memory so next time you Start taking measurements the new data will be added to the current data.
EndSave() Stops taking performance measurements and opens a snapshot with current data in the profiler. After opening the snapshot, measurement data is reset.
EndDrop() Stops taking performance measurements and resets current measurement data.
Detach() Detaches profiler from an application.

TimelineProfiler Class Properties

ItemTypeDescription
CanDetach bool Indicates whether detach operation is possible.
IsActive bool Indicates whether profiler is active (either attached or the application is executed under profiler).

TimelineProfiler Class Methods

ItemDescription
Begin() Creates a blank snapshot and starts collecting timeline data.
EndSave() Stops taking measurements and opens a snapshot with current data in the profiler. After opening the snapshot, measurement data is reset.
EndDrop() Stops taking performance measurements and resets current measurement data.
Detach() Detaches profiler from an application.

SelfAttach Class Properties

ItemTypeDescription
State enum SelfApiState {None, Inactive, Active} Indicates the profiler state:
  • None - the profiler is not available.
  • Inactive - the profiler is available. Profiling control is not available.
  • Active - the profiler is available. Profiling can be controlled via API or the controller window.

SelfAttach Class Methods

ItemDescription
Attach(BaseProfilerConfig baseConfig) Attaches the profiler to the calling application with supplied configuration baseConfig.
Show() Shows the profiling controller to a user.

BaseProfilingConfig Class Public Fields

ItemTypeDescription
ProfilingControlKind enum ProfilingControlKind {None, Manual, Api} Defines the profiling control method:
  • None - no control.
  • Manual - control through the Controller window.
  • Api - control through API.
ProfilingType enum ProfilingType {Performance, Memory, Timeline} Defines the profiling method:
  • Performance - performance profiling.
  • Memory - memory profiling (used by the dotMemory profiler).
  • Timeline - timeline profiling.
RedistDir string Defines location of dotTrace SDK redistributables. By default, they are searched in the same folder where JetBrains.Profiler.Windows.Api.dll is located.

BaseSnapshotProfilingConfig Class Public Fields

ItemTypeDescription
SaveDir string Defines a path and a base file name for the resulting snapshot. Required for this configuration.
SnapshotFormat enum {Compressed, Uncompressed} Defines a file format for a snapshot: compressed or uncompressed. By default, it is compressed.

SaveSnapshotProfilingConfig Class Public Fields

ItemTypeDescription
ListFile string Defines a file name for a file which lists snapshots collected during profiling. Required for this configuration.
Do NOT create this file manually, it will be created automatically during profiling!
Do NOT open this file until the SelfAttach.State is in the None state!

ExecutableSnapshotProfilingConfig Class Public Fields

ItemTypeDescription
Executable string Defines the path to the executable file to run after profiling is completed. The snapshot path will be passed as a parameter to this executable file. Required for this configuration.

See Also

Last modified: 3 April 2017