Removed the WebUI. Removed the Modules
This commit is contained in:
@@ -1,13 +0,0 @@
|
||||
using System;
|
||||
using DiscordBotCore.Interfaces.Modules;
|
||||
|
||||
namespace DiscordBotCore.Others.Exceptions;
|
||||
|
||||
public class ModuleMethodNotFound : Exception
|
||||
{
|
||||
private IModule _SearchedModule;
|
||||
public ModuleMethodNotFound(IModule module, string methodName) : base($"Method not found {methodName} in module {module.Name}")
|
||||
{
|
||||
_SearchedModule = module;
|
||||
}
|
||||
}
|
||||
@@ -1,15 +0,0 @@
|
||||
using System;
|
||||
using DiscordBotCore.Interfaces.Modules;
|
||||
|
||||
namespace DiscordBotCore.Others.Exceptions;
|
||||
|
||||
public class ModuleNotFound : Exception
|
||||
{
|
||||
public ModuleNotFound(string moduleName) : base($"Module not found: {moduleName}")
|
||||
{
|
||||
}
|
||||
|
||||
public ModuleNotFound(ModuleType moduleType) : base($"No module with type {moduleType} found")
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -1,16 +0,0 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace DiscordBotCore.Others.Exceptions
|
||||
{
|
||||
internal class ModuleNotFoundException<T> : Exception
|
||||
{
|
||||
private Type _type = typeof(T);
|
||||
public ModuleNotFoundException() : base($"No module loaded with this signature: {typeof(T)}")
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,31 +0,0 @@
|
||||
using System.Collections.Generic;
|
||||
using DiscordBotCore.Interfaces.Modules;
|
||||
using DiscordBotCore.Modules;
|
||||
|
||||
namespace DiscordBotCore.Others.Exceptions;
|
||||
|
||||
public class ModuleRequirement
|
||||
{
|
||||
private List<ModuleType> RequiredModulesWithType { get; }
|
||||
private List<string> RequiredModulesWithName { get; }
|
||||
|
||||
public ModuleRequirement()
|
||||
{
|
||||
RequiredModulesWithType = new List<ModuleType>();
|
||||
RequiredModulesWithName = new List<string>();
|
||||
}
|
||||
|
||||
public void AddType (ModuleType moduleType)
|
||||
{
|
||||
RequiredModulesWithType.Add(moduleType);
|
||||
}
|
||||
|
||||
public void AddName (string moduleName)
|
||||
{
|
||||
RequiredModulesWithName.Add(moduleName);
|
||||
}
|
||||
|
||||
public bool RequireAny => RequiredModulesWithType.Count > 0 || RequiredModulesWithName.Count > 0;
|
||||
public IList<ModuleType> RequiredModulesWithTypes => RequiredModulesWithType ;
|
||||
public IList<string> RequiredModulesWithNames => RequiredModulesWithName;
|
||||
}
|
||||
Reference in New Issue
Block a user