tgstation-server 6.0.1
The /tg/station 13 server suite
Loading...
Searching...
No Matches
PipeCommands.cs
Go to the documentation of this file.
2{
6 public static class PipeCommands
7 {
11 public const string CommandStop = "stop";
12
16 public const string CommandGracefulShutdown = "graceful";
17
21 public const string CommandDetachingShutdown = "detach";
22
26 public const string CommandStartupComplete = "times_up_lets_do_this";
27
28#if NET6_0_OR_GREATER
32 public static System.Collections.Generic.IReadOnlyList<string> AllCommands { get; } = new[]
33 {
38 };
39#endif
40
46 public static int? GetServiceCommandId(string command)
47 => command switch
48 {
49 CommandStop => 128, // Windows only allows commands 128-256: https://stackoverflow.com/a/62858106
52 CommandStartupComplete or _ => null,
53 };
54 }
55}
Values able to be passed via the update file path.
Definition: PipeCommands.cs:7
static ? int GetServiceCommandId(string command)
Gets the int value of a given command .
const string CommandDetachingShutdown
Stops the server ASAP, detaching the watchdog for any running instances.
Definition: PipeCommands.cs:21
const string CommandStop
Stops the server ASAP, shutting down any running instances.
Definition: PipeCommands.cs:11
const string CommandGracefulShutdown
Stops the server eventually, waiting for the games in any running instances to reboot.
Definition: PipeCommands.cs:16
const string CommandStartupComplete
Indicates that the host has finished initializing.
Definition: PipeCommands.cs:26