From 134f86e8d5c414409631b25b8c6f0ee45fbd8631 Mon Sep 17 00:00:00 2001 From: David Walter Seikel Date: Thu, 3 Nov 2016 21:44:39 +1000 Subject: Initial update to OpenSim 0.8.2.1 source code. --- ThirdParty/SmartThreadPool/Exceptions.cs | 82 ++++++++++++++++++++++---------- 1 file changed, 56 insertions(+), 26 deletions(-) (limited to 'ThirdParty/SmartThreadPool/Exceptions.cs') diff --git a/ThirdParty/SmartThreadPool/Exceptions.cs b/ThirdParty/SmartThreadPool/Exceptions.cs index c454709..6c6a88b 100644 --- a/ThirdParty/SmartThreadPool/Exceptions.cs +++ b/ThirdParty/SmartThreadPool/Exceptions.cs @@ -1,8 +1,7 @@ -// Ami Bar -// amibar@gmail.com - using System; +#if !(_WINDOWS_CE) using System.Runtime.Serialization; +#endif namespace Amib.Threading { @@ -11,22 +10,39 @@ namespace Amib.Threading /// /// Represents an exception in case IWorkItemResult.GetResult has been canceled /// - [Serializable] - public sealed class WorkItemCancelException : ApplicationException + public sealed partial class WorkItemCancelException : Exception { - public WorkItemCancelException() : base() + public WorkItemCancelException() { } - public WorkItemCancelException(string message) : base(message) + public WorkItemCancelException(string message) + : base(message) { } - public WorkItemCancelException(string message, Exception e) : base(message, e) + public WorkItemCancelException(string message, Exception e) + : base(message, e) { } + } - public WorkItemCancelException(SerializationInfo si, StreamingContext sc) : base(si, sc) + /// + /// Represents an exception in case IWorkItemResult.GetResult has been timed out + /// + public sealed partial class WorkItemTimeoutException : Exception + { + public WorkItemTimeoutException() + { + } + + public WorkItemTimeoutException(string message) + : base(message) + { + } + + public WorkItemTimeoutException(string message, Exception e) + : base(message, e) { } } @@ -34,22 +50,33 @@ namespace Amib.Threading /// /// Represents an exception in case IWorkItemResult.GetResult has been timed out /// - [Serializable] - public sealed class WorkItemTimeoutException : ApplicationException + public sealed partial class WorkItemResultException : Exception { - public WorkItemTimeoutException() : base() + public WorkItemResultException() { } - public WorkItemTimeoutException(string message) : base(message) + public WorkItemResultException(string message) + : base(message) { } - public WorkItemTimeoutException(string message, Exception e) : base(message, e) + public WorkItemResultException(string message, Exception e) + : base(message, e) { } + } - public WorkItemTimeoutException(SerializationInfo si, StreamingContext sc) : base(si, sc) + +#if !(_WINDOWS_CE) && !(_SILVERLIGHT) && !(WINDOWS_PHONE) + /// + /// Represents an exception in case IWorkItemResult.GetResult has been canceled + /// + [Serializable] + public sealed partial class WorkItemCancelException + { + public WorkItemCancelException(SerializationInfo si, StreamingContext sc) + : base(si, sc) { } } @@ -58,24 +85,27 @@ namespace Amib.Threading /// Represents an exception in case IWorkItemResult.GetResult has been timed out /// [Serializable] - public sealed class WorkItemResultException : ApplicationException + public sealed partial class WorkItemTimeoutException { - public WorkItemResultException() : base() - { - } - - public WorkItemResultException(string message) : base(message) - { - } - - public WorkItemResultException(string message, Exception e) : base(message, e) + public WorkItemTimeoutException(SerializationInfo si, StreamingContext sc) + : base(si, sc) { } + } - public WorkItemResultException(SerializationInfo si, StreamingContext sc) : base(si, sc) + /// + /// Represents an exception in case IWorkItemResult.GetResult has been timed out + /// + [Serializable] + public sealed partial class WorkItemResultException + { + public WorkItemResultException(SerializationInfo si, StreamingContext sc) + : base(si, sc) { } } +#endif + #endregion } -- cgit v1.1