Table of Contents

Class RuntimeResult

Namespace
Discord.Commands
Assembly
Discord.Net.Commands.dll
public abstract class RuntimeResult : IResult
Inheritance
RuntimeResult
Implements
Inherited Members

Constructors

RuntimeResult(CommandError?, string)

Initializes a new RuntimeResult class with the type of error and reason.

protected RuntimeResult(CommandError? error, string reason)

Parameters

error CommandError?

The type of failure, or null if none.

reason string

The reason of failure.

Properties

Error

Describes the error type that may have occurred during the operation.

public CommandError? Error { get; }

Property Value

CommandError?

A CommandError indicating the type of error that may have occurred during the operation; null if the operation was successful.

IsSuccess

Indicates whether the operation was successful or not.

public bool IsSuccess { get; }

Property Value

bool

true if the result is positive; otherwise false.

Reason

Describes the execution reason or result.

public string Reason { get; }

Property Value

string

Methods

ToString()

Returns a string that represents the current object.

public override string ToString()

Returns

string

A string that represents the current object.