source: TFP-WebServer/CommandExtensions/src/Commands/Exception.cs@ 498

Last change on this file since 498 was 487, checked in by alloc, 5 months ago

1.1.0.1 Release for V 1.0

File size: 648 bytes
Line 
1using System;
2using System.Collections.Generic;
3using JetBrains.Annotations;
4
5namespace CommandExtensions.Commands {
6 [UsedImplicitly]
7 public class ConsoleCmdException : ConsoleCmdAbstract {
8 public override string[] getCommands () {
9 return new[] { "exception" };
10 }
11
12 public override bool AllowedInMainMenu => true;
13
14 public override void Execute (List<string> _params, CommandSenderInfo _senderInfo) {
15 Log.Out ("Test info");
16 Log.Warning ("Test warning");
17 Log.Error ("Test error");
18 throw new Exception ("Test exception");
19 }
20
21 public override string getDescription () {
22 return "Throw an exception / log messages";
23 }
24 }
25}
Note: See TracBrowser for help on using the repository browser.