PageRenderTime 59ms CodeModel.GetById 35ms RepoModel.GetById 0ms app.codeStats 0ms

/Mercurial.Net/MercurialException.cs

#
C# | 67 lines | 24 code | 4 blank | 39 comment | 0 complexity | 177e91e7f5976d12876d5a16b978c81b MD5 | raw file
Possible License(s): BSD-3-Clause, GPL-2.0
  1. using System;
  2. using System.Runtime.Serialization;
  3. namespace Mercurial
  4. {
  5. /// <summary>
  6. /// Represents errors related to Mercurial.
  7. /// </summary>
  8. [Serializable]
  9. public class MercurialException : Exception
  10. {
  11. /// <summary>
  12. /// Initializes a new instance of the <see cref = "MercurialException" /> class.
  13. /// </summary>
  14. /// <param name="info">The <see cref = "T:System.Runtime.Serialization.SerializationInfo" /> that holds the serialized object data about the exception being thrown.</param>
  15. /// <param name="context">The <see cref = "T:System.Runtime.Serialization.StreamingContext" /> that contains contextual information about the source or destination.</param>
  16. /// <exception cref = "T:System.ArgumentNullException">
  17. /// The <paramref name = "info" /> parameter is null.
  18. /// </exception>
  19. /// <exception cref = "T:System.Runtime.Serialization.SerializationException">
  20. /// The class name is null or <see cref = "P:System.Exception.HResult" /> is zero (0).
  21. /// </exception>
  22. protected MercurialException(SerializationInfo info, StreamingContext context)
  23. : base(info, context)
  24. {
  25. // Do nothing here
  26. }
  27. /// <summary>
  28. /// Initializes a new instance of the <see cref = "MercurialException" /> class.
  29. /// </summary>
  30. public MercurialException()
  31. {
  32. // Do nothing here
  33. }
  34. /// <summary>
  35. /// Initializes a new instance of the <see cref = "MercurialException" /> class
  36. /// with a specific error message.
  37. /// </summary>
  38. /// <param name="message">The message.</param>
  39. public MercurialException(string message)
  40. : base(message)
  41. {
  42. // Do nothing here
  43. }
  44. /// <summary>
  45. /// Initializes a new instance of the <see cref = "MercurialException" /> class
  46. /// s with a specified error message and a reference to the inner exception
  47. /// that is the cause of this exception.
  48. /// </summary>
  49. /// <param name="message">
  50. /// The error message that explains the reason for the exception.
  51. /// </param>
  52. /// <param name="innerException">
  53. /// The exception that is the cause of the current exception,
  54. /// or a <c>null</c> reference (<c>Nothing</c> in Visual Basic)
  55. /// if no inner exception is specified.
  56. /// </param>
  57. public MercurialException(string message, Exception innerException)
  58. : base(message, innerException)
  59. {
  60. // Do nothing here
  61. }
  62. }
  63. }