/*
Copyright (C) 2014-2019 de4dot@gmail.com
This file is part of dnSpy
dnSpy is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
dnSpy 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 General Public License for more details.
You should have received a copy of the GNU General Public License
along with dnSpy. If not, see .
*/
using System;
namespace dnSpy.Debugger.DotNet.Metadata {
///
/// Thrown when a type or a member couldn't be found
///
[Serializable]
public class MemberNotFoundException : Exception {
///
/// Constructor
///
/// Message
public MemberNotFoundException(string message) : base(message) { }
}
///
/// Thrown when a type couldn't be found
///
[Serializable]
public sealed class TypeNotFoundException : MemberNotFoundException {
///
/// Constructor
///
/// Type that couldn't be found
public TypeNotFoundException(string typeName) : base("Couldn't find type: " + typeName) { }
}
///
/// Thrown when a field couldn't be found
///
[Serializable]
public sealed class FieldNotFoundException : MemberNotFoundException {
///
/// Constructor
///
/// Field that couldn't be found
public FieldNotFoundException(string fieldName) : base("Couldn't find field: " + fieldName) { }
}
///
/// Thrown when a method couldn't be found
///
[Serializable]
public sealed class MethodNotFoundException : MemberNotFoundException {
///
/// Constructor
///
/// Method that couldn't be found
public MethodNotFoundException(string methodName) : base("Couldn't find method: " + methodName) { }
}
///
/// Thrown when a property couldn't be found
///
[Serializable]
public sealed class PropertyNotFoundException : MemberNotFoundException {
///
/// Constructor
///
/// Property that couldn't be found
public PropertyNotFoundException(string propertyName) : base("Couldn't find property: " + propertyName) { }
}
///
/// Thrown when an event couldn't be found
///
[Serializable]
public sealed class EventNotFoundException : MemberNotFoundException {
///
/// Constructor
///
/// Event that couldn't be found
public EventNotFoundException(string eventName) : base("Couldn't find event: " + eventName) { }
}
}