Initial commit
This commit is contained in:
19
C#/CommandManager/ManagerTester/Commands/TestCmd.cs
Normal file
19
C#/CommandManager/ManagerTester/Commands/TestCmd.cs
Normal file
@@ -0,0 +1,19 @@
|
||||
using System;
|
||||
using CommandManager.Attributes;
|
||||
|
||||
namespace ManagerTester.Commands {
|
||||
[Command(Name = "test", Alias = new[]{"test2", "test3"}, Description = "This is a Test Command")]
|
||||
public class TestCmd {
|
||||
|
||||
[CommandArgument(ArgNum = 0, Name = "Vorname", Suggestions = new[]{"Werner", "Alfred"})]
|
||||
public string FirstName { get; set; }
|
||||
|
||||
[CommandArgument(ArgNum = 1, Name = "Nachname", Suggestions = new[]{"Meyer", "Müller"})]
|
||||
public string LastName { get; set; }
|
||||
|
||||
[CommandHandler]
|
||||
public void OnCommand() {
|
||||
Console.WriteLine(FirstName + " " + LastName);
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user