DataCollectorNotifications Class
Used by custom test adapters to raise events for diagnostic data adapters.
Assembly: Microsoft.VisualStudio.QualityTools.ExecutionCommon (in Microsoft.VisualStudio.QualityTools.ExecutionCommon.dll)
| Name | Description | |
|---|---|---|
![]() | DataCollectorNotifications() | Initializes a new instance of the DataCollectorNotifications class. |
| Name | Description | |
|---|---|---|
![]() | Equals(Object^) | (Inherited from Object.) |
![]() | Finalize() | (Inherited from Object.) |
![]() | GetHashCode() | (Inherited from Object.) |
![]() | GetType() | (Inherited from Object.) |
![]() | MemberwiseClone() | (Inherited from Object.) |
![]() | RaiseCustomEvent(CustomNotificationEventArgs^) | Raises a custom event by using the provided event arguments. |
![]() | RaiseCustomEvent(CustomNotificationEventArgs^, NotificationBroadcastLevel) | Raises a custom event by using the provided event arguments and indication of broadcast level. |
![]() | RaiseCustomEventAsync(CustomNotificationEventArgs^) | Asynchronously raises a custom event by using the provided event arguments. |
![]() | RaiseCustomEventAsync(CustomNotificationEventArgs^, NotificationBroadcastLevel) | Asynchronously raises a custom event by using the provided event arguments and indication of broadcast level. |
![]() | RaiseCustomEventAsync(CustomNotificationEventArgs^, NotificationBroadcastLevel, Object^) | Asynchronously raises a custom event by using the provided event arguments, indication of broadcast level, and user token. |
![]() | RaiseTestFailedEvent(ITestElement^, TestCaseFailureType) | Raises a TestCaseFailed event to notify diagnostic data adapters that the test case has failed. |
![]() | ToString() | (Inherited from Object.) |
| Name | Description | |
|---|---|---|
![]() | CustomEventCompleted | Raised by the testing framework when a diagnostic data adapter has finished handling an asynchronous event. |
Legacy Code Example
To use a DataCollectorNotifications object in a custom test adapter class, you first add the IDataCollectionAwareTestAdapter to the class declaration for your derived test adapter.
public class MyTestAdapter : ITestAdapter, IDataCollectionAwareTestAdapter
Then in your test adapter code, you create a DataCollectors property that returns a DataCollectorNotifications object.
public DataCollectorNotifications DataCollectors { get; set; }
You can then use this object to raise events for diagnostic data adapters.
DataCollectors.RaiseCustomEvent(
new MyCustomDataEventArgs(),
NotificationBroadCastLevel.All);
Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.


