SynchronizationLockException.cs 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. // Licensed to the .NET Foundation under one or more agreements.
  2. // The .NET Foundation licenses this file to you under the MIT license.
  3. // See the LICENSE file in the project root for more information.
  4. /*=============================================================================
  5. **
  6. **
  7. **
  8. ** Purpose: Wait(), Notify() or NotifyAll() was called from an unsynchronized
  9. ** block of code.
  10. **
  11. **
  12. =============================================================================*/
  13. using System.Runtime.Serialization;
  14. namespace System.Threading
  15. {
  16. [Serializable]
  17. [System.Runtime.CompilerServices.TypeForwardedFrom("mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089")]
  18. public class SynchronizationLockException : SystemException
  19. {
  20. public SynchronizationLockException()
  21. : base(SR.Arg_SynchronizationLockException)
  22. {
  23. HResult = HResults.COR_E_SYNCHRONIZATIONLOCK;
  24. }
  25. public SynchronizationLockException(string message)
  26. : base(message)
  27. {
  28. HResult = HResults.COR_E_SYNCHRONIZATIONLOCK;
  29. }
  30. public SynchronizationLockException(string message, Exception innerException)
  31. : base(message, innerException)
  32. {
  33. HResult = HResults.COR_E_SYNCHRONIZATIONLOCK;
  34. }
  35. protected SynchronizationLockException(SerializationInfo info, StreamingContext context) : base(info, context)
  36. {
  37. }
  38. }
  39. }