DkmRuntimeCustomDataBreakpoint.Create(DkmRuntimeInstance, Guid, DkmThread, String, DkmDataAccessStopMask, DkmDataItem) 方法

定义

创建新的 DkmRuntimeCustomDataBreakpoint 对象。Creates a new DkmRuntimeCustomDataBreakpoint object. 创建后,断点处于禁用状态,必须显式启用。After creation, the breakpoint is in the disabled state, and must be explicitly enabled. 调用方负责在完成后关闭创建的对象。The caller is responsible for closing the created object after they are done.

此 API 是在 Visual Studio 16 RTM (VS16RTM) 中引入的。This API was introduced in Visual Studio 16 RTM (DkmApiVersion.VS16RTM).

public:
 static Microsoft::VisualStudio::Debugger::Breakpoints::DkmRuntimeCustomDataBreakpoint ^ Create(Microsoft::VisualStudio::Debugger::DkmRuntimeInstance ^ RuntimeInstance, Guid SourceId, Microsoft::VisualStudio::Debugger::DkmThread ^ Thread, System::String ^ Description, Microsoft::VisualStudio::Debugger::Breakpoints::DkmDataAccessStopMask Access, Microsoft::VisualStudio::Debugger::DkmDataItem ^ DataItem);
public static Microsoft.VisualStudio.Debugger.Breakpoints.DkmRuntimeCustomDataBreakpoint Create (Microsoft.VisualStudio.Debugger.DkmRuntimeInstance RuntimeInstance, Guid SourceId, Microsoft.VisualStudio.Debugger.DkmThread Thread, string Description, Microsoft.VisualStudio.Debugger.Breakpoints.DkmDataAccessStopMask Access, Microsoft.VisualStudio.Debugger.DkmDataItem DataItem);
static member Create : Microsoft.VisualStudio.Debugger.DkmRuntimeInstance * Guid * Microsoft.VisualStudio.Debugger.DkmThread * string * Microsoft.VisualStudio.Debugger.Breakpoints.DkmDataAccessStopMask * Microsoft.VisualStudio.Debugger.DkmDataItem -> Microsoft.VisualStudio.Debugger.Breakpoints.DkmRuntimeCustomDataBreakpoint
Public Shared Function Create (RuntimeInstance As DkmRuntimeInstance, SourceId As Guid, Thread As DkmThread, Description As String, Access As DkmDataAccessStopMask, DataItem As DkmDataItem) As DkmRuntimeCustomDataBreakpoint

参数

RuntimeInstance
DkmRuntimeInstance

中DkmRuntimeInstance 类表示加载到 DkmProcess 中的执行环境,其中包含要调试的代码。[In] The DkmRuntimeInstance class represents an execution environment which is loaded into a DkmProcess and which contains code to be debugged.

SourceId
Guid

中标识对象的源。[In] Identifies the source of an object. 当多个组件可能创建类的实例时,SourceIds 用于在方案中启用筛选。SourceIds are used to enable filtering in scenarios when multiple components may be creating instances of a class. 例如,源 id 可用于确定断点是否来自 AD7 AL (ex: user 断点或其他) SDM 级别可见的断点,而不是可能由另一个组件创建的断点 (例如,用于单步执行) 的内部断点。For example, source ids can be used to determine if a breakpoint comes from the AD7 AL (ex: user breakpoint, or other breakpoint visible at the SDM level) instead of a breakpoint which may be created by another component (for example an internal breakpoint used for stepping).

Thread
DkmThread

[In,可选]应在其上激发此断点的线程。[In,Optional] Thread on which this breakpoint should fire. 如果为 null,则将在所有线程上触发断点。If null, the breakpoint will fire on all threads.

Description
String

中有关 where/如何设置自定义数据断点的说明。[In] A description of where/how to set the custom data breakpoint. 此字符串的格式为监视器依赖项。The format of this string is monitor dependent.

Access
DkmDataAccessStopMask

中屏蔽应激发数据断点的原因。[In] Mask of reasons why the data breakpoint should fire. 例如,如果设置了 "Write",则在写入内存位置时将激发断点。For example, if 'Write' is set, then the breakpoint will fire when the memory location is written.

DataItem
DkmDataItem

[In,可选]要添加到新的 DkmRuntimeCustomDataBreakpoint 实例的数据对象。[In,Optional] Data object to add to the new DkmRuntimeCustomDataBreakpoint instance. 如果调用方不需要添加数据项,则传递 "null"。Pass 'null' in the case that the caller doesn't need to add a data item.

返回

DkmRuntimeCustomDataBreakpoint

弄此方法调用的结果。[Out] Result of this method call.

适用于