Table of Contents

Class ServiceControlTask

Namespace
ArcanaDevelopment.adTempus.Client
Assembly
ArcanaDevelopment.adTempus.Client.dll

Task that stops or starts a Windows service

public sealed class ServiceControlTask : Task
Inheritance
object
ServiceControlTask

Properties

ClassID

The Class ID for the object

[IgnoreDataMember]
public override ClassID ClassID { get; }

Property Value

ClassID

ClassKeyName

The key name for the class.

public override string ClassKeyName { get; }

Property Value

string

Remarks

This name the name used by adTempus to identify the class and is intended for programmatic use only. Use the ClassName for a user-friendly name.

ControlType

The type of action to perform on the service

public ServiceControlType ControlType { get; set; }

Property Value

ServiceControlType

IsDependent

Indicates whether the object is a dependent of (owned by) another object

[IgnoreDataMember]
public override bool IsDependent { get; }

Property Value

bool

Remarks

An independent object (IsDependent is false) is an object that can exist on its own without being part of another object. For example, Jobs, Job Groups, etc.

A dependent object (IsDependent is true) is a part of another object. For example, a JobStep cannot exist independently of a Job, so the JobStep is dependent.

Dependent objects cannot be directly fetched from the server: they are only fetched as part of the object they belong to. They also cannot be saved or deleted independently: they are automatically saved or deleted when the owning object is saved or deleted.

Options

Additional options for the task

public ServiceControlOptions Options { get; set; }

Property Value

ServiceControlOptions

ServiceName

The name of the service to control

public string ServiceName { get; set; }

Property Value

string

Remarks

This must be the name of the service, not the display name

StartupParameters

Optional parameters to pass to the service when starting it

public string StartupParameters { get; set; }

Property Value

string

SupportedResponseEvents

Gets a list of the events that are supported for Responses associated with this task.

public override ReadOnlyCollection<SupportedResponseEvent> SupportedResponseEvents { get; }

Property Value

ReadOnlyCollection<SupportedResponseEvent>

TargetComputer

The name or address of the remote computer to control the service on.

public string TargetComputer { get; set; }

Property Value

string

Remarks

Set to null or empty string to control a service on the same computer as the adTempus service.

Methods

GetObjectDescription()

Gets a description of the object's key settings.

protected override string GetObjectDescription()

Returns

string

Remarks

This method is called by GetDescription() to get a user-friendly description of the object (such as its key settings) for display to the user. The description should contain enough information to distinguish this object from others of the same class.

WriteToConfigurationReport(IADTObjectConfigurationReportWriter)

Writes the object and any contained objects to a configuration report

public override void WriteToConfigurationReport(IADTObjectConfigurationReportWriter reportBuilder)

Parameters

NameTypeDescription
reportBuilder IADTObjectConfigurationReportWriter

The report builder to write the object to.

Inherited Members