<PackageReference Include="Castle.Windsor" Version="3.0.0.2001" />

ComponentNotFoundException

Exception threw when a request for a component cannot be satisfied because the component does not exist in the container
using System; using System.Runtime.Serialization; namespace Castle.MicroKernel { [Serializable] public class ComponentNotFoundException : Exception { public Type Service { get; set; } public string Name { get; set; } public ComponentNotFoundException(string name) : this(name, $"""{name}""") { } public ComponentNotFoundException(string name, string message) : base(message) { Name = name; } public ComponentNotFoundException(Type service, string message) : base(message) { Service = service; } public ComponentNotFoundException(Type service) : this(service, $"""{service.FullName}""") { } public ComponentNotFoundException(SerializationInfo info, StreamingContext context) : base(info, context) { } } }