Table of Contents

Class WindowsService

Namespace
CENTREL.XIA.Configuration.Types
Assembly
CENTREL.XIA.Configuration.Types.dll

Represents a service running on a Windows machine.

public class WindowsService : GlobalSerializableClassicBase, IComparable<WindowsService>
Inheritance
WindowsService
Implements

Constructors

WindowsService()

Initializes a new instance of the CENTREL.XIA.Configuration.Types.WindowsService class.

public WindowsService()

Properties

AutoStart

Gets whether the service is configured to autostart.

[Browsable(false)]
public bool AutoStart { get; }

Property Value

bool

DependsOnServices

Gets or sets the internal names of the services on which this service depends.

public SerializableStringCollection DependsOnServices { get; set; }

Property Value

SerializableStringCollection

Description

Gets or sets the description of the Windows service - for example "Registers and updates IP addresses and DNS records for this computer".

public string Description { get; set; }

Property Value

string

Remarks

This property is ignored by the DataComparer as the value of this property can vary between the same service on different operating systems.

DesktopInteract

Gets or sets whether the service is allowed to interact with the desktop.

public BooleanOption DesktopInteract { get; set; }

Property Value

BooleanOption

DisplayName

Gets or sets the display name of this Windows service - for example "DHCP Server".

public string DisplayName { get; set; }

Property Value

string

ExecutionType

Gets or sets the type of service - for example "OwnProcess" or "ShareProcess".

public WindowsServiceExecutionType ExecutionType { get; set; }

Property Value

WindowsServiceExecutionType

ExecutionTypeString

Gets the type of service - for example "Own Process" or "Share Process".

public string ExecutionTypeString { get; set; }

Property Value

string

IsStarted

Gets or sets whether the service was started at the time of the scan.

public BooleanOption IsStarted { get; set; }

Property Value

BooleanOption

Name

Gets or sets the internal name of this Windows service - for example "DHCPServer".

public string Name { get; set; }

Property Value

string

PathName

Gets or sets the absolute path to the executable file that is executed by this service.

public string PathName { get; set; }

Property Value

string

ProcessId

Gets or sets the unique process ID (PID) of this service.

public int ProcessId { get; set; }

Property Value

int

Recovery

Gets or sets the recovery settings for this service. This applies to Windows 2000 and above only.

public WindowsServiceRecoverySettings Recovery { get; set; }

Property Value

WindowsServiceRecoverySettings

StartMode

Gets or sets the start mode of this service - for example "Auto", "Manual", "Disabled".

public WindowsServiceStartMode StartMode { get; set; }

Property Value

WindowsServiceStartMode

StartModeString

Gets the start mode of this service as a human readable string.

public string StartModeString { get; set; }

Property Value

string

StartName

Gets or sets the name of the user account assigned to run this service - for example "LocalSystem" or "CORP\ServiceAccount".

public string StartName { get; set; }

Property Value

string

State

Gets or sets the state of the service at the time of the scan - for example "Stopped", "Running", "Paused".

public WindowsServiceState State { get; set; }

Property Value

WindowsServiceState

StateString

Gets the state of the service at the time of the scan - for example "Stopped", "Running", "Paused".

public string StateString { get; set; }

Property Value

string

StateStringValueType

Gets the value type for the "StateString" field, for the data comparer.

public DataComparableValueType StateStringValueType { get; }

Property Value

DataComparableValueType

Remarks

Manually started services, and services that are managed by the system are marked as volatile.

Methods

ToString()

Returns the display name of this Windows service.

public override string ToString()

Returns

string

The display name of this Windows service.