- Add Result Code and Help function

This commit is contained in:
Stone_Red
2022-04-23 14:38:12 +02:00
parent 81dd31b9f3
commit aad3ad502c
8 changed files with 302 additions and 55 deletions
+17
View File
@@ -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;
}
}