SharpZipBaseException.cs 2.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. using System;
  2. using System.Runtime.Serialization;
  3. namespace System.Net.ApiService.Compression.Exceptions
  4. {
  5. /// <summary>
  6. /// SharpZipBaseException is the base exception class for SharpZipLib.
  7. /// All library exceptions are derived from this.
  8. /// </summary>
  9. /// <remarks>NOTE: Not all exceptions thrown will be derived from this class.
  10. /// A variety of other exceptions are possible for example <see cref="ArgumentNullException"></see></remarks>
  11. [Serializable]
  12. public class SharpZipBaseException : System.Exception
  13. {
  14. /// <summary>
  15. /// Initializes a new instance of the SharpZipBaseException class.
  16. /// </summary>
  17. public SharpZipBaseException()
  18. {
  19. }
  20. /// <summary>
  21. /// Initializes a new instance of the SharpZipBaseException class with a specified error message.
  22. /// </summary>
  23. /// <param name="message">A message describing the exception.</param>
  24. public SharpZipBaseException(string message)
  25. : base(message)
  26. {
  27. }
  28. /// <summary>
  29. /// Initializes a new instance of the SharpZipBaseException class with a specified
  30. /// error message and a reference to the inner exception that is the cause of this exception.
  31. /// </summary>
  32. /// <param name="message">A message describing the exception.</param>
  33. /// <param name="innerException">The inner exception</param>
  34. public SharpZipBaseException(string message, Exception innerException)
  35. : base(message, innerException)
  36. {
  37. }
  38. /// <summary>
  39. /// Initializes a new instance of the SharpZipBaseException class with serialized data.
  40. /// </summary>
  41. /// <param name="info">
  42. /// The System.Runtime.Serialization.SerializationInfo that holds the serialized
  43. /// object data about the exception being thrown.
  44. /// </param>
  45. /// <param name="context">
  46. /// The System.Runtime.Serialization.StreamingContext that contains contextual information
  47. /// about the source or destination.
  48. /// </param>
  49. protected SharpZipBaseException(SerializationInfo info, StreamingContext context)
  50. : base(info, context)
  51. {
  52. }
  53. }
  54. }