DesktopException class

Namespace Runic.Desktop · Runic.Desktop 0.7.0-preview.5

public class DesktopException : Exception

Inherits or implements Exception.

Represents a redacted, stable Desktop operation failure.

Constructors

DesktopException

public DesktopException(DesktopErrorCategory category, string code, string message, bool retryable = false, Exception? innerException = null, string? correlationId = null)

Creates a Desktop failure with a stable category and code.

Parameters

category

The stable error category.

code

The stable, machine-readable error code, such as origin-not-allowed.

message

The safe, redacted message.

retryable

Whether repeating the operation may succeed.

innerException

The underlying failure, kept for diagnostics only.

correlationId

The diagnostic correlation identity, or null to generate one.

Exceptions

ArgumentException

code is empty or whitespace.

ArgumentNullException

code is null.

Properties

Category

public DesktopErrorCategory Category { get; }

Gets the stable error category.

Code

public string Code { get; }

Gets the stable, machine-readable error code.

CorrelationId

public string CorrelationId { get; }

Gets the opaque identity used to correlate redacted frontend and host diagnostics.

Retryable

public bool Retryable { get; }

Gets whether repeating the operation may succeed.