PSQueueException.cs 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. using Quadarax.Foundation.Core.Attributes;
  2. using Quadarax.Foundation.Core.Exceptions;
  3. namespace qdr.fnd.core.pqueue.Exceptions
  4. {
  5. public class PSQueueException: CodeException<PSQueueException.ErrorCodes>
  6. {
  7. #region *** Error Codes ***
  8. public enum ErrorCodes : int
  9. {
  10. [ErrorMessage("Cannot start, queue is already running.")]
  11. PsQueueIsRunning = 5000,
  12. [ErrorMessage("Cannot stop, queue is not running.")]
  13. PsQueueIsNotRunning = 5001,
  14. }
  15. #endregion
  16. #region *** Constructors ***
  17. /// <inheritdoc />
  18. public PSQueueException(ErrorCodes code, Exception innerException) : base(code, innerException)
  19. {
  20. }
  21. /// <inheritdoc />
  22. public PSQueueException(ErrorCodes code) : base(code)
  23. {
  24. }
  25. /// <inheritdoc />
  26. public PSQueueException(ErrorCodes code, params object[] messageArguments) : base(code, messageArguments)
  27. {
  28. }
  29. /// <inheritdoc />
  30. public PSQueueException(ErrorCodes code, Exception innerException, params object[] messageArguments) : base(code, innerException, messageArguments)
  31. {
  32. }
  33. #endregion
  34. }
  35. }