diff options
author | vnugent <public@vaughnnugent.com> | 2023-11-02 01:50:05 -0400 |
---|---|---|
committer | vnugent <public@vaughnnugent.com> | 2023-11-02 01:50:05 -0400 |
commit | 9768aa7713826d49a6c2ea1025caa4b87d62e5e8 (patch) | |
tree | 327525a94b1fbe8b11591eeb1b3d2941a6e58c06 /lib/VNLib.Plugins.Extensions.Loading/src/Exceptions | |
parent | c5b9f9b64933a288362fc08bea8a461e5e260b16 (diff) |
also carried away
Diffstat (limited to 'lib/VNLib.Plugins.Extensions.Loading/src/Exceptions')
5 files changed, 212 insertions, 0 deletions
diff --git a/lib/VNLib.Plugins.Extensions.Loading/src/Exceptions/ConcreteTypeAmbiguousMatchException.cs b/lib/VNLib.Plugins.Extensions.Loading/src/Exceptions/ConcreteTypeAmbiguousMatchException.cs new file mode 100644 index 0000000..6118b64 --- /dev/null +++ b/lib/VNLib.Plugins.Extensions.Loading/src/Exceptions/ConcreteTypeAmbiguousMatchException.cs @@ -0,0 +1,44 @@ +/* +* Copyright (c) 2023 Vaughn Nugent +* +* Library: VNLib +* Package: VNLib.Plugins.Extensions.Loading +* File: ConcreteTypeAmbiguousMatchException.cs +* +* ConcreteTypeAmbiguousMatchException.cs is part of VNLib.Plugins.Extensions.Loading +* which is part of the larger VNLib collection of libraries and utilities. +* +* VNLib.Plugins.Extensions.Loading is free software: you can redistribute it and/or modify +* it under the terms of the GNU Affero General Public License as +* published by the Free Software Foundation, either version 3 of the +* License, or (at your option) any later version. +* +* VNLib.Plugins.Extensions.Loading is distributed in the hope that it will be useful, +* but WITHOUT ANY WARRANTY; without even the implied warranty of +* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +* GNU Affero General Public License for more details. +* +* You should have received a copy of the GNU Affero General Public License +* along with this program. If not, see https://www.gnu.org/licenses/. +*/ + +using System; + +namespace VNLib.Plugins.Extensions.Loading +{ + /// <summary> + /// Raised when a concrete type is found but is ambiguous because more than one + /// type implements the desired abstract type. + /// </summary> + public sealed class ConcreteTypeAmbiguousMatchException : ConcreteTypeException + { + public ConcreteTypeAmbiguousMatchException(string message) : base(message) + { } + + public ConcreteTypeAmbiguousMatchException(string message, Exception innerException) : base(message, innerException) + { } + + public ConcreteTypeAmbiguousMatchException() + { } + } +} diff --git a/lib/VNLib.Plugins.Extensions.Loading/src/Exceptions/ConcreteTypeException.cs b/lib/VNLib.Plugins.Extensions.Loading/src/Exceptions/ConcreteTypeException.cs new file mode 100644 index 0000000..29f080a --- /dev/null +++ b/lib/VNLib.Plugins.Extensions.Loading/src/Exceptions/ConcreteTypeException.cs @@ -0,0 +1,44 @@ +/* +* Copyright (c) 2023 Vaughn Nugent +* +* Library: VNLib +* Package: VNLib.Plugins.Extensions.Loading +* File: ConcreteTypeException.cs +* +* ConcreteTypeException.cs is part of VNLib.Plugins.Extensions.Loading +* which is part of the larger VNLib collection of libraries and utilities. +* +* VNLib.Plugins.Extensions.Loading is free software: you can redistribute it and/or modify +* it under the terms of the GNU Affero General Public License as +* published by the Free Software Foundation, either version 3 of the +* License, or (at your option) any later version. +* +* VNLib.Plugins.Extensions.Loading is distributed in the hope that it will be useful, +* but WITHOUT ANY WARRANTY; without even the implied warranty of +* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +* GNU Affero General Public License for more details. +* +* You should have received a copy of the GNU Affero General Public License +* along with this program. If not, see https://www.gnu.org/licenses/. +*/ + +using System; + +namespace VNLib.Plugins.Extensions.Loading +{ + /// <summary> + /// Base class for concrete type loading exceptions. Raised when searching + /// for a concrete type fails. + /// </summary> + public class ConcreteTypeException : TypeLoadException + { + public ConcreteTypeException() : base() + { } + + public ConcreteTypeException(string? message) : base(message) + { } + + public ConcreteTypeException(string? message, Exception? innerException) : base(message, innerException) + { } + } +} diff --git a/lib/VNLib.Plugins.Extensions.Loading/src/Exceptions/ConcreteTypeNotFoundException.cs b/lib/VNLib.Plugins.Extensions.Loading/src/Exceptions/ConcreteTypeNotFoundException.cs new file mode 100644 index 0000000..523726b --- /dev/null +++ b/lib/VNLib.Plugins.Extensions.Loading/src/Exceptions/ConcreteTypeNotFoundException.cs @@ -0,0 +1,41 @@ +/* +* Copyright (c) 2023 Vaughn Nugent +* +* Library: VNLib +* Package: VNLib.Plugins.Extensions.Loading +* File: ConcreteTypeNotFoundException.cs +* +* ConcreteTypeNotFoundException.cs is part of VNLib.Plugins.Extensions.Loading +* which is part of the larger VNLib collection of libraries and utilities. +* +* VNLib.Plugins.Extensions.Loading is free software: you can redistribute it and/or modify +* it under the terms of the GNU Affero General Public License as +* published by the Free Software Foundation, either version 3 of the +* License, or (at your option) any later version. +* +* VNLib.Plugins.Extensions.Loading is distributed in the hope that it will be useful, +* but WITHOUT ANY WARRANTY; without even the implied warranty of +* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +* GNU Affero General Public License for more details. +* +* You should have received a copy of the GNU Affero General Public License +* along with this program. If not, see https://www.gnu.org/licenses/. +*/ + +using System; + +namespace VNLib.Plugins.Extensions.Loading +{ + /// <summary> + /// The requested concrete type was not found in the assembly + /// </summary> + public sealed class ConcreteTypeNotFoundException : ConcreteTypeException + { + public ConcreteTypeNotFoundException(string message) : base(message) + { } + public ConcreteTypeNotFoundException(string message, Exception innerException) : base(message, innerException) + { } + public ConcreteTypeNotFoundException() + { } + } +} diff --git a/lib/VNLib.Plugins.Extensions.Loading/src/Exceptions/ConfigurationValidationException.cs b/lib/VNLib.Plugins.Extensions.Loading/src/Exceptions/ConfigurationValidationException.cs new file mode 100644 index 0000000..ebf4d9e --- /dev/null +++ b/lib/VNLib.Plugins.Extensions.Loading/src/Exceptions/ConfigurationValidationException.cs @@ -0,0 +1,42 @@ +/* +* Copyright (c) 2023 Vaughn Nugent +* +* Library: VNLib +* Package: VNLib.Plugins.Extensions.Loading +* File: ConfigurationValidationException.cs +* +* ConfigurationValidationException.cs is part of VNLib.Plugins.Extensions.Loading which is part of the larger +* VNLib collection of libraries and utilities. +* +* VNLib.Plugins.Extensions.Loading is free software: you can redistribute it and/or modify +* it under the terms of the GNU Affero General Public License as +* published by the Free Software Foundation, either version 3 of the +* License, or (at your option) any later version. +* +* VNLib.Plugins.Extensions.Loading is distributed in the hope that it will be useful, +* but WITHOUT ANY WARRANTY; without even the implied warranty of +* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +* GNU Affero General Public License for more details. +* +* You should have received a copy of the GNU Affero General Public License +* along with this program. If not, see https://www.gnu.org/licenses/. +*/ + +using System; + +namespace VNLib.Plugins.Extensions.Loading +{ + /// <summary> + /// An exception raised when a configuration validation exception has occured + /// </summary> + public class ConfigurationValidationException : Exception + { + public ConfigurationValidationException(string message) : base(message) + {} + + public ConfigurationValidationException(string message, Exception innerException) : base(message, innerException) + {} + public ConfigurationValidationException() + {} + } +} diff --git a/lib/VNLib.Plugins.Extensions.Loading/src/Exceptions/MissingDependencyException.cs b/lib/VNLib.Plugins.Extensions.Loading/src/Exceptions/MissingDependencyException.cs new file mode 100644 index 0000000..b07badc --- /dev/null +++ b/lib/VNLib.Plugins.Extensions.Loading/src/Exceptions/MissingDependencyException.cs @@ -0,0 +1,41 @@ +/* +* Copyright (c) 2023 Vaughn Nugent +* +* Library: VNLib +* Package: VNLib.Plugins.Extensions.Loading +* File: MissingDependencyException.cs +* +* MissingDependencyException.cs is part of VNLib.Plugins.Extensions.Loading +* which is part of the larger VNLib collection of libraries and utilities. +* +* VNLib.Plugins.Extensions.Loading is free software: you can redistribute it and/or modify +* it under the terms of the GNU Affero General Public License as +* published by the Free Software Foundation, either version 3 of the +* License, or (at your option) any later version. +* +* VNLib.Plugins.Extensions.Loading is distributed in the hope that it will be useful, +* but WITHOUT ANY WARRANTY; without even the implied warranty of +* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +* GNU Affero General Public License for more details. +* +* You should have received a copy of the GNU Affero General Public License +* along with this program. If not, see https://www.gnu.org/licenses/. +*/ + +using System; + +namespace VNLib.Plugins.Extensions.Loading +{ + /// <summary> + /// Raised when a required dependency is missing and the program cannot continue + /// </summary> + public sealed class MissingDependencyException : Exception + { + public MissingDependencyException(string message) : base(message) + { } + public MissingDependencyException(string message, Exception innerException) : base(message, innerException) + { } + public MissingDependencyException() + { } + } +} |