dotMemory 2017.1 Help

API Reference

MemoryProfiler Class

Properties of the MemoryProfiler Class

IsActive boolCheck whether the API is enabled.
CanControlAllocations boolCheck whether the recording of the creation stack trace information is turned on.
CanDetach boolCheck whether the profiler was attached to an already running application.

Methods of the MemoryProfiler Class

Dump() Get a memory snapshot.
EnableAllocations() Turn on recording of the creation stack trace information.
DisableAllocations() Turn off recording of the creation stack trace information.
Detach() Detach dotMemory from the profiled process. This method is suitable only in case you attach the profiler to an already running process.

SelfAttach Class

Properties of the SelfAttach Class

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.

Methods of the SelfAttach Class

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

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

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. Use only the Compressed format! Uncompressed is not supported by dotMemory.

SaveSnapshotProfilingConfig Class Public Fields

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

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.
Last modified: 24 August 2017

See Also