Table of Contents

Class OptionHandlerStatus

Namespace
Albatross.CommandLine
Assembly
Albatross.CommandLine.dll

Records the execution status of an option handler, including success/failure and any error information.

public record OptionHandlerStatus : IEquatable<OptionHandlerStatus>
Inheritance
OptionHandlerStatus
Implements
Inherited Members

Constructors

OptionHandlerStatus(string, bool, string?, Exception?)

Creates a new option handler status.

public OptionHandlerStatus(string name, bool status, string? message, Exception? exception)

Parameters

name string

The name of the option or argument.

status bool

Whether the handler succeeded.

message string

An optional descriptive message.

exception Exception

The exception that occurred, if any.

Properties

Exception

Gets the exception that occurred during handler execution, if any.

public Exception? Exception { get; }

Property Value

Exception

Message

Gets an optional message describing the result or error.

public string? Message { get; }

Property Value

string

Name

Gets the name of the option or argument that was processed.

public string Name { get; }

Property Value

string

Success

Gets a value indicating whether the handler executed successfully.

public bool Success { get; }

Property Value

bool