tgstation-server  4.4.0
The /tg/station 13 server suite
JobException.cs
Go to the documentation of this file.
1 using System;
3 
4 namespace Tgstation.Server.Host.Jobs
5 {
9  public sealed class JobException : Exception
10  {
14  public ErrorCode? ErrorCode { get; }
15 
19  public JobException()
20  {
21  }
22 
27  public JobException(string message) : base(message)
28  {
29  }
30 
36  public JobException(string message, Exception innerException) : base(message, innerException)
37  {
38  }
39 
44  public JobException(ErrorCode errorCode) : base(errorCode.Describe())
45  {
46  ErrorCode = errorCode;
47  }
48 
54  public JobException(ErrorCode errorCode, Exception innerException) : base(errorCode.Describe(), innerException)
55  {
56  ErrorCode = errorCode;
57  }
58  }
59 }
JobException(ErrorCode errorCode)
Construct a JobException with a errorCode .
Definition: JobException.cs:44
ErrorCode
Types of ErrorMessages that the API may return.
Definition: ErrorCode.cs:10
JobException(string message)
Construct a JobException with a message
Definition: JobException.cs:27
JobException(ErrorCode errorCode, Exception innerException)
Construct a JobException with a errorCode and innerException .
Definition: JobException.cs:54
Operation exceptions thrown from the context of a Models.Job
Definition: JobException.cs:9
JobException()
Construct a JobException
Definition: JobException.cs:19
JobException(string message, Exception innerException)
Construct a JobException with a message and innerException
Definition: JobException.cs:36