mirror of
https://github.com/Stone-Red-Code/Commander.NET.git
synced 2026-09-04 00:46:08 +02:00
- Add Result Code and Help function
This commit is contained in:
@@ -0,0 +1,17 @@
|
||||
namespace Commander_Net;
|
||||
|
||||
public class CommandResult
|
||||
{
|
||||
public ResultType ResultType { get; }
|
||||
public string Message { get; }
|
||||
|
||||
public static CommandResult Success => new CommandResult(ResultType.Success);
|
||||
public static CommandResult InvalidInput => new CommandResult(ResultType.InvalidInput);
|
||||
public static CommandResult InternalError => new CommandResult(ResultType.InternalError);
|
||||
|
||||
public CommandResult(ResultType type, string message = "")
|
||||
{
|
||||
ResultType = type;
|
||||
Message = message;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user