ActivityMonitorAttribute Class
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
This attribute declares that an Activity class should be run as a monitor activity.
public ref class ActivityMonitorAttribute sealed : Attribute
[System.AttributeUsage(System.AttributeTargets.Class | System.AttributeTargets.Interface, AllowMultiple=false, Inherited=false)]
public sealed class ActivityMonitorAttribute : Attribute
type ActivityMonitorAttribute = class
inherit Attribute
Public NotInheritable Class ActivityMonitorAttribute
Inherits Attribute
- Inheritance
-
ActivityMonitorAttribute
- Attributes
[Activity("Monitor Computer")]
[ActivityMonitor(Interval=15)]
public class MonitorComputer
{
private IPAddress computer;
[ActivityInput("Hostname or Adress")]
public IPAddress Computer
{
set { computer = value; }
}
[ActivityOutput]
IPStatus Status
{
get { new Ping().Send(computer).Status; }
}
}
Monitor activities, unlike standard task activities, will be invoked repeatedly until the workflow that contains them is stopped. Furthermore, your object will be kept alive until the workflow is stopped which means that that any state information will be maintained between subsequent invocations.
Activity |
Initializes a new instance of the ActivityMonitorAttributeclass |
Tuote | Versiot |
---|---|
System Center Orch SDK | 2012, 2016 |