ServiceSnapshot record

Namespace Runic.Platform.Administration.Windows.Services in Runic.Platform.Administration.Windows 0.23.0

public sealed record ServiceSnapshot : IEquatable<ServiceSnapshot>

Inherits or implements IEquatable.

Configuration and status read from Windows. BinaryCommandLine includes arguments.

Constructors

ServiceSnapshot

public ServiceSnapshot(string Name, string DisplayName, string BinaryCommandLine, string AccountName, ImmutableArray<string> Dependencies, ServiceStartMode StartMode, uint NativeServiceType, uint NativeErrorControl, string LoadOrderGroup, string Description, bool DelayedAutomaticStart, ServiceFailurePolicy FailurePolicy, ServiceStatus Status)

Configuration and status read from Windows. BinaryCommandLine includes arguments.

Properties

AccountName

public string AccountName { get; init; }

No documentation.

BinaryCommandLine

public string BinaryCommandLine { get; init; }

No documentation.

DelayedAutomaticStart

public bool DelayedAutomaticStart { get; init; }

No documentation.

Dependencies

public ImmutableArray<string> Dependencies { get; init; }

No documentation.

Description

public string Description { get; init; }

No documentation.

DisplayName

public string DisplayName { get; init; }

No documentation.

ExecutablePath

public string ExecutablePath { get; init; }

The executable of ServiceSnapshot.BinaryCommandLine, without quotes and arguments, as the Service Control Manager parses it.

Remarks

A quoted path is taken as written. For an unquoted path with spaces, such as C:\Program Files\App\svc.exe -k, the SCM starts the first prefix that exists as a file, trying C:\Program.exe first; on the local computer this property is found the same way. On a remote computer, or when no prefix exists, it is the shortest prefix ending in .exe, otherwise the first word. Environment references such as %SystemRoot% are kept; empty when the command line is empty.

FailurePolicy

public ServiceFailurePolicy FailurePolicy { get; init; }

No documentation.

LoadOrderGroup

public string LoadOrderGroup { get; init; }

No documentation.

Name

public string Name { get; init; }

No documentation.

NativeErrorControl

public uint NativeErrorControl { get; init; }

No documentation.

NativeServiceType

public uint NativeServiceType { get; init; }

No documentation.

StartMode

public ServiceStartMode StartMode { get; init; }

No documentation.

Status

public ServiceStatus Status { get; init; }

No documentation.