Changed accessibility modifiers in light of new structure.
This commit is contained in:
parent
48cf2b80ca
commit
de68e62eb4
@ -4,7 +4,7 @@ using System.Text;
|
||||
|
||||
namespace RecrownedGTK.Tools.CommandProcessor
|
||||
{
|
||||
internal class CommandEngine
|
||||
public class CommandEngine
|
||||
{
|
||||
public bool running = true;
|
||||
public readonly List<EngineCommand> commands;
|
||||
@ -14,12 +14,12 @@ namespace RecrownedGTK.Tools.CommandProcessor
|
||||
commands = new List<EngineCommand>();
|
||||
}
|
||||
|
||||
internal void Run()
|
||||
public void Run(IUserInput input)
|
||||
{
|
||||
while (running)
|
||||
{
|
||||
ConsoleUtilities.WriteWrappedLine("\nAwaiting command.");
|
||||
string command = Console.ReadLine();
|
||||
string command = input.GetInput();
|
||||
try
|
||||
{
|
||||
Process(command);
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
namespace RecrownedGTK.Tools.CommandProcessor.Commands
|
||||
{
|
||||
internal class ClearConsoleCommand : EngineCommand
|
||||
public class ClearConsoleCommand : EngineCommand
|
||||
{
|
||||
public ClearConsoleCommand() : base("clear")
|
||||
{
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
namespace RecrownedGTK.Tools.CommandProcessor.Commands
|
||||
{
|
||||
internal class HelpCommand : EngineCommand
|
||||
public class HelpCommand : EngineCommand
|
||||
{
|
||||
CommandEngine commandEngine;
|
||||
|
||||
|
6
RecrownedGTK.Tools/CommandProcessor/IUserInput.cs
Normal file
6
RecrownedGTK.Tools/CommandProcessor/IUserInput.cs
Normal file
@ -0,0 +1,6 @@
|
||||
namespace RecrownedGTK.Tools.CommandProcessor {
|
||||
public interface IUserInput
|
||||
{
|
||||
string GetInput();
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user