Class InvalidOverloadException
Thrown when the command service fails to build a command due to a problem with its overload.
Inheritance
System.Object
System.Exception
InvalidOverloadException
Namespace: DisCatSharp.CommandsNext.Exceptions
Assembly: DisCatSharp.CommandsNext.dll
Syntax
public sealed class InvalidOverloadException : Exception, ISerializable
Constructors
| Improve this Doc View SourceInvalidOverloadException(String, MethodInfo)
Creates a new InvalidOverloadException.
Declaration
public InvalidOverloadException(string message, MethodInfo method)
Parameters
Type | Name | Description |
---|---|---|
System.String | message | Exception message. |
System.Reflection.MethodInfo | method | Method that caused the problem. |
InvalidOverloadException(String, MethodInfo, ParameterInfo)
Creates a new InvalidOverloadException.
Declaration
public InvalidOverloadException(string message, MethodInfo method, ParameterInfo parameter)
Parameters
Type | Name | Description |
---|---|---|
System.String | message | Exception message. |
System.Reflection.MethodInfo | method | Method that caused the problem. |
System.Reflection.ParameterInfo | parameter | Method argument that caused the problem. |
Properties
| Improve this Doc View SourceMethod
Gets the method that caused this exception.
Declaration
public MethodInfo Method { get; }
Property Value
Type | Description |
---|---|
System.Reflection.MethodInfo |
Parameter
Gets or sets the argument that caused the problem. This can be null.
Declaration
public ParameterInfo Parameter { get; }
Property Value
Type | Description |
---|---|
System.Reflection.ParameterInfo |
Methods
| Improve this Doc View SourceToString()
Returns a string representation of this InvalidOverloadException.
Declaration
public override string ToString()
Returns
Type | Description |
---|---|
System.String | A string representation. |
Overrides
System.Exception.ToString()