From 230fcbdcbdd35576137123d6b19257adfff849bc Mon Sep 17 00:00:00 2001 From: Drew Noakes Date: Fri, 19 Feb 2016 20:26:50 +0000 Subject: [PATCH] Obsoletion messages explain that APIs will be removed in NetMQ 4.0 --- .../OutgoingSocketExtensionsTests.cs | 2 +- .../ReceivingSocketExtensionsTests.cs | 2 +- src/NetMQ/Blob.cs | 4 +- src/NetMQ/Core/Options.cs | 12 ++-- src/NetMQ/Core/ZmqSocketOption.cs | 2 +- src/NetMQ/Devices/ForwarderDevice.cs | 4 +- src/NetMQ/Devices/QueueDevice.cs | 4 +- src/NetMQ/Devices/StreamerDevice.cs | 4 +- src/NetMQ/ErrorCode.cs | 68 +++++++++---------- src/NetMQ/ErrorPollingException.cs | 2 +- src/NetMQ/IOutgoingSocket.cs | 2 +- src/NetMQ/IReceivingSocket.cs | 2 +- src/NetMQ/InProcActors/Actor.cs | 6 +- src/NetMQ/InProcActors/IShimHandler.cs | 2 +- src/NetMQ/InProcActors/KnownMessages.cs | 4 +- src/NetMQ/InProcActors/Shim.cs | 2 +- src/NetMQ/Monitoring/NetMQMonitor.cs | 4 +- src/NetMQ/Msg.cs | 8 +-- src/NetMQ/NetMQActor.cs | 10 +-- src/NetMQ/NetMQBeacon.cs | 2 +- src/NetMQ/NetMQContext.cs | 2 +- src/NetMQ/NetMQException.cs | 2 +- src/NetMQ/NetMQMessage.cs | 4 +- src/NetMQ/NetMQScheduler.cs | 4 +- src/NetMQ/NetMQSocket.cs | 14 ++-- src/NetMQ/NetMQSocketEventArgs.cs | 4 +- src/NetMQ/OutgoingSocketExtensions.cs | 22 +++--- src/NetMQ/Poller.cs | 8 +-- src/NetMQ/ReceivingSocketExtensions.cs | 58 ++++++++-------- src/NetMQ/SendReceiveOptions.cs | 4 +- src/NetMQ/SocketEvents.cs | 2 +- src/NetMQ/SocketOptions.cs | 14 ++-- src/NetMQ/Sockets/PublisherSocket.cs | 2 +- src/NetMQ/Sockets/PullSocket.cs | 2 +- src/NetMQ/Sockets/PushSocket.cs | 2 +- src/NetMQ/Sockets/SubscriberSocket.cs | 2 +- src/NetMQ/ZmqNamespacePlaceholder.cs | 2 +- 37 files changed, 147 insertions(+), 147 deletions(-) diff --git a/src/NetMQ.Tests/OutgoingSocketExtensionsTests.cs b/src/NetMQ.Tests/OutgoingSocketExtensionsTests.cs index 23b5c56..386a8c2 100644 --- a/src/NetMQ.Tests/OutgoingSocketExtensionsTests.cs +++ b/src/NetMQ.Tests/OutgoingSocketExtensionsTests.cs @@ -14,7 +14,7 @@ public MockOutgoingSocket(TrySendDelegate action) m_action = action; } - [Obsolete("Use Send(ref Msg, bool) or TrySend(ref Msg,TimeSpan, bool) instead.")] + [Obsolete("Use Send(ref Msg, bool) or TrySend(ref Msg,TimeSpan, bool) instead. This will be removed in NetMQ 4.0.")] public void Send(ref Msg msg, SendReceiveOptions options) { diff --git a/src/NetMQ.Tests/ReceivingSocketExtensionsTests.cs b/src/NetMQ.Tests/ReceivingSocketExtensionsTests.cs index 24b2aa8..51ddcad 100644 --- a/src/NetMQ.Tests/ReceivingSocketExtensionsTests.cs +++ b/src/NetMQ.Tests/ReceivingSocketExtensionsTests.cs @@ -14,7 +14,7 @@ internal class MockReceivingSocket : IReceivingSocket [Obsolete] public SendReceiveOptions LastOptions { get; private set; } - [Obsolete("Use Receive(ref Msg) or TryReceive(ref Msg,TimeSpan) instead.")] + [Obsolete("Use Receive(ref Msg) or TryReceive(ref Msg,TimeSpan) instead. This will be removed in NetMQ 4.0.")] public void Receive(ref Msg msg, SendReceiveOptions options) { LastOptions = options; diff --git a/src/NetMQ/Blob.cs b/src/NetMQ/Blob.cs index 64604b0..ef3d1c3 100644 --- a/src/NetMQ/Blob.cs +++ b/src/NetMQ/Blob.cs @@ -29,7 +29,7 @@ namespace NetMQ /// Class Blob serves to hold a byte-array buffer and methods for creating and accessing it. /// Use NetMQFrame instead; Blob is still present simply for backward compatibility. /// - [Obsolete("Use NetMQFrame instead of Blob")] + [Obsolete("Use NetMQFrame instead of Blob. This will be removed in NetMQ 4.0.")] public class Blob { [NotNull] @@ -45,7 +45,7 @@ public Blob([NotNull] byte[] data, int size) { m_buffer = new byte[size]; - Buffer.BlockCopy(data, 0, m_buffer, 0, size); + Buffer.BlockCopy(data, 0, m_buffer, 0, size); } /// diff --git a/src/NetMQ/Core/Options.cs b/src/NetMQ/Core/Options.cs index ad30d0b..1ca2101 100644 --- a/src/NetMQ/Core/Options.cs +++ b/src/NetMQ/Core/Options.cs @@ -3,19 +3,19 @@ Copyright (c) 2009-2011 250bpm s.r.o. Copyright (c) 2011 VMware, Inc. Copyright (c) 2007-2015 Other contributors as noted in the AUTHORS file - + This file is part of 0MQ. - + 0MQ is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version. - + 0MQ is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details. - + You should have received a copy of the GNU Lesser General Public License along with this program. If not, see . */ @@ -145,7 +145,7 @@ public Options() /// /// Get or set the maximum size of message to handle. /// - [Obsolete("Use MaxMessageSize")] + [Obsolete("Use MaxMessageSize. This will be removed in NetMQ 4.0.")] public long Maxmsgsize { get { return this.MaxMessageSize; } @@ -226,7 +226,7 @@ public long Maxmsgsize /// Get or set the timeout for receive operations for this socket. /// The default value is -1, which means no timeout. /// - [Obsolete("Pass a TimeSpan value directly to socket receive methods instead.")] + [Obsolete("Pass a TimeSpan value directly to socket receive methods instead. This will be removed in NetMQ 4.0.")] public int ReceiveTimeout { get; set; } /// diff --git a/src/NetMQ/Core/ZmqSocketOption.cs b/src/NetMQ/Core/ZmqSocketOption.cs index eec6ea6..41ab3e3 100644 --- a/src/NetMQ/Core/ZmqSocketOption.cs +++ b/src/NetMQ/Core/ZmqSocketOption.cs @@ -162,7 +162,7 @@ internal enum ZmqSocketOption /// /// Specifies the amount of time after which a synchronous receive call will time out. /// - [Obsolete("Pass a TimeSpan value directly to socket receive methods instead.")] + [Obsolete("Pass a TimeSpan value directly to socket receive methods instead. This will be removed in NetMQ 4.0.")] ReceiveTimeout = 27, /// diff --git a/src/NetMQ/Devices/ForwarderDevice.cs b/src/NetMQ/Devices/ForwarderDevice.cs index 85c4cd8..423dda7 100644 --- a/src/NetMQ/Devices/ForwarderDevice.cs +++ b/src/NetMQ/Devices/ForwarderDevice.cs @@ -31,7 +31,7 @@ public class ForwarderDevice : DeviceBase /// The endpoint used to bind the frontend socket. /// The endpoint used to bind the backend socket. /// The for the device. - [Obsolete("Use non context version")] + [Obsolete("Use non context version. This will be removed in NetMQ 4.0.")] public ForwarderDevice(NetMQContext context, string frontendBindAddress, string backendBindAddress, DeviceMode mode = DeviceMode.Threaded) : base(context.CreateSubscriberSocket(), context.CreatePublisherSocket(), mode) @@ -48,7 +48,7 @@ public ForwarderDevice(NetMQContext context, string frontendBindAddress, string /// The endpoint used to bind the frontend socket. /// The endpoint used to bind the backend socket. /// The for the device. - [Obsolete("Use non context version")] + [Obsolete("Use non context version. This will be removed in NetMQ 4.0.")] public ForwarderDevice(NetMQContext context, INetMQPoller poller, string frontendBindAddress, string backendBindAddress, DeviceMode mode = DeviceMode.Threaded) : base(poller, context.CreateSubscriberSocket(), context.CreatePublisherSocket(), mode) diff --git a/src/NetMQ/Devices/QueueDevice.cs b/src/NetMQ/Devices/QueueDevice.cs index 13427d5..991b297 100644 --- a/src/NetMQ/Devices/QueueDevice.cs +++ b/src/NetMQ/Devices/QueueDevice.cs @@ -22,7 +22,7 @@ public class QueueDevice : DeviceBase /// The endpoint used to bind the frontend socket. /// The endpoint used to bind the backend socket. /// The for the device. - [Obsolete("Use non context version")] + [Obsolete("Use non context version. This will be removed in NetMQ 4.0.")] public QueueDevice(NetMQContext context, string frontendBindAddress, string backendBindAddress, DeviceMode mode = DeviceMode.Threaded) : base(context.CreateRouterSocket(), context.CreateDealerSocket(), mode) { @@ -38,7 +38,7 @@ public QueueDevice(NetMQContext context, string frontendBindAddress, string back /// The endpoint used to bind the frontend socket. /// The endpoint used to bind the backend socket. /// The for the device. - [Obsolete("Use non context version")] + [Obsolete("Use non context version. This will be removed in NetMQ 4.0.")] public QueueDevice(NetMQContext context, INetMQPoller poller, string frontendBindAddress, string backendBindAddress, DeviceMode mode = DeviceMode.Threaded) : base(poller, context.CreateRouterSocket(), context.CreateDealerSocket(), mode) { diff --git a/src/NetMQ/Devices/StreamerDevice.cs b/src/NetMQ/Devices/StreamerDevice.cs index 69ecd37..47c4f3f 100644 --- a/src/NetMQ/Devices/StreamerDevice.cs +++ b/src/NetMQ/Devices/StreamerDevice.cs @@ -20,7 +20,7 @@ public class StreamerDevice : DeviceBase /// The endpoint used to bind the frontend socket. /// The endpoint used to bind the backend socket. /// The for the device. - [Obsolete("Use non context version")] + [Obsolete("Use non context version. This will be removed in NetMQ 4.0.")] public StreamerDevice(NetMQContext context, string frontendBindAddress, string backendBindAddress, DeviceMode mode = DeviceMode.Threaded) : base(context.CreatePullSocket(), context.CreatePushSocket(), mode) @@ -37,7 +37,7 @@ public StreamerDevice(NetMQContext context, string frontendBindAddress, string b /// The endpoint used to bind the frontend socket. /// The endpoint used to bind the backend socket. /// The for the device. - [Obsolete("Use non context version")] + [Obsolete("Use non context version. This will be removed in NetMQ 4.0.")] public StreamerDevice(NetMQContext context, INetMQPoller poller, string frontendBindAddress, string backendBindAddress, DeviceMode mode = DeviceMode.Threaded) : base(poller, context.CreatePullSocket(), context.CreatePushSocket(), mode) diff --git a/src/NetMQ/ErrorCode.cs b/src/NetMQ/ErrorCode.cs index 8319bed..830fdf2 100644 --- a/src/NetMQ/ErrorCode.cs +++ b/src/NetMQ/ErrorCode.cs @@ -40,7 +40,7 @@ public enum ErrorCode /// /// The connection is still in progress. /// - [Obsolete("Use InProgress")] + [Obsolete("Use InProgress. This will be removed in NetMQ 4.0.")] InProgres = 36, /// @@ -148,201 +148,201 @@ public enum ErrorCode /// /// The provided endpoint is not connected. /// - [Obsolete("Use EndpointNotFound")] + [Obsolete("Use EndpointNotFound. This will be removed in NetMQ 4.0.")] ENOENT = 2, /// /// The operation was interrupted by a signal. /// - [Obsolete("Not in use")] + [Obsolete("Not in use. This will be removed in NetMQ 4.0.")] EINTR = 4, /// /// Permission denied /// - [Obsolete("Use AccessDenied")] + [Obsolete("Use AccessDenied. This will be removed in NetMQ 4.0.")] EACCESS = 13, /// /// The provided context is invalid. /// - [Obsolete("Use Fault")] + [Obsolete("Use Fault. This will be removed in NetMQ 4.0.")] EFAULT = 14, /// /// The endpoint supplied is invalid. /// - [Obsolete("Use Invalid")] + [Obsolete("Use Invalid. This will be removed in NetMQ 4.0.")] EINVAL = 22, /// /// Non-blocking mode was requested and the message cannot be sent at the moment. /// - [Obsolete("Use TryAgain")] + [Obsolete("Use TryAgain. This will be removed in NetMQ 4.0.")] EAGAIN = 35, /// /// The connection is still in progress. /// - [Obsolete("Use InProgress")] + [Obsolete("Use InProgress. This will be removed in NetMQ 4.0.")] EINPROGRESS = 36, /// /// The requested transport protocol is not supported. /// - [Obsolete("Use ProtocolNotSupported")] + [Obsolete("Use ProtocolNotSupported. This will be removed in NetMQ 4.0.")] EPROTONOSUPPORT = 43, /// /// That operation is not supported by this socket type. /// - [Obsolete("Not in use")] + [Obsolete("Not in use. This will be removed in NetMQ 4.0.")] ENOTSUP = 45, /// /// The requested address is already in use. /// - [Obsolete("Use AddressAlreadyInUse")] + [Obsolete("Use AddressAlreadyInUse. This will be removed in NetMQ 4.0.")] EADDRINUSE = 48, /// /// The requested address was not available. /// For Bind operations, that can mean the address was not local. /// - [Obsolete("Use AddressNotAvailable")] + [Obsolete("Use AddressNotAvailable. This will be removed in NetMQ 4.0.")] EADDRNOTAVAIL = 49, /// /// The network appears to be down. /// - [Obsolete("Use NetworkDown")] + [Obsolete("Use NetworkDown. This will be removed in NetMQ 4.0.")] ENETDOWN = 50, /// /// There is not enough buffer space for the requested operation. /// - [Obsolete("Use NoBufferSpaceAvailable")] + [Obsolete("Use NoBufferSpaceAvailable. This will be removed in NetMQ 4.0.")] ENOBUFS = 55, /// /// Unused /// - [Obsolete("Not in use")] + [Obsolete("Not in use. This will be removed in NetMQ 4.0.")] EISCONN = 56, /// /// The socket is not connected. /// - [Obsolete("Use NotConnected")] + [Obsolete("Use NotConnected. This will be removed in NetMQ 4.0.")] ENOTCONN = 57, /// /// The connection was refused. /// - [Obsolete("Use ConnectionRefused")] + [Obsolete("Use ConnectionRefused. This will be removed in NetMQ 4.0.")] ECONNREFUSED = 61, /// /// The host is not reachable. /// - [Obsolete("Use HostUnreachable")] + [Obsolete("Use HostUnreachable. This will be removed in NetMQ 4.0.")] EHOSTUNREACH = 65, /// /// This is the value chosen for beginning the range of 0MQ error codes. /// - [Obsolete("Use BaseErrorNumber")] + [Obsolete("Use BaseErrorNumber. This will be removed in NetMQ 4.0.")] ZMQ_HAUSNUMERO = BaseErrorNumber, /// /// The provided socket was invalid. /// - [Obsolete("Not in use")] + [Obsolete("Not in use. This will be removed in NetMQ 4.0.")] ENOTSOCK = BaseErrorNumber + 9, /// /// The message is too long. /// - [Obsolete("Use MessageSize")] + [Obsolete("Use MessageSize. This will be removed in NetMQ 4.0.")] EMSGSIZE = BaseErrorNumber + 10, /// /// The address family is not supported by this protocol. /// - [Obsolete("Use AddressFamilyNotSupported")] + [Obsolete("Use AddressFamilyNotSupported. This will be removed in NetMQ 4.0.")] EAFNOSUPPORT = BaseErrorNumber + 11, /// /// The network is apparently not reachable. /// - [Obsolete("Use NetworkUnreachable")] + [Obsolete("Use NetworkUnreachable. This will be removed in NetMQ 4.0.")] ENETUNREACH = BaseErrorNumber + 12, /// /// The connection-attempt has apparently been aborted. /// - [Obsolete("Use ConnectionAborted")] + [Obsolete("Use ConnectionAborted. This will be removed in NetMQ 4.0.")] ECONNABORTED = BaseErrorNumber + 13, /// /// The connection has apparently been reset. /// - [Obsolete("Use ConnectionReset")] + [Obsolete("Use ConnectionReset. This will be removed in NetMQ 4.0.")] ECONNRESET = BaseErrorNumber + 14, /// /// The operation timed-out. /// - [Obsolete("Use TimedOut")] + [Obsolete("Use TimedOut. This will be removed in NetMQ 4.0.")] ETIMEDOUT = BaseErrorNumber + 16, /// /// The network was reset. /// - [Obsolete("Use NetworkReset")] + [Obsolete("Use NetworkReset. This will be removed in NetMQ 4.0.")] ENETRESET = BaseErrorNumber + 18, /// /// The operation cannot be performed on this socket at the moment due /// to the socket not being in the appropriate state. /// - [Obsolete("Use FiniteStateMachine")] + [Obsolete("Use FiniteStateMachine. This will be removed in NetMQ 4.0.")] EFSM = BaseErrorNumber + 51, /// /// The requested transport protocol is not compatible with the socket type. /// - [Obsolete("Not in use")] + [Obsolete("Not in use. This will be removed in NetMQ 4.0.")] ENOCOMPATPROTO = BaseErrorNumber + 52, /// /// The context associated with the specified socket has already been terminated. /// - [Obsolete("Use ContextTerminated")] + [Obsolete("Use ContextTerminated. This will be removed in NetMQ 4.0.")] ETERM = BaseErrorNumber + 53, /// /// No I/O thread is available to accomplish this task. /// - [Obsolete("Use EmptyThread")] + [Obsolete("Use EmptyThread. This will be removed in NetMQ 4.0.")] EMTHREAD = BaseErrorNumber + 54, /// /// Unused /// - [Obsolete("Not In Use")] + [Obsolete("Not In Use. This will be removed in NetMQ 4.0.")] EIOEXC = BaseErrorNumber + 105, /// /// Unused /// - [Obsolete] + [Obsolete("This will be removed in NetMQ 4.0.")] ESOCKET = BaseErrorNumber + 106, /// /// Too many sockets for this process. /// - [Obsolete("Use TooManyOpenSockets")] + [Obsolete("Use TooManyOpenSockets. This will be removed in NetMQ 4.0.")] EMFILE = BaseErrorNumber + 107 } } \ No newline at end of file diff --git a/src/NetMQ/ErrorPollingException.cs b/src/NetMQ/ErrorPollingException.cs index 1b9ed45..465aefd 100644 --- a/src/NetMQ/ErrorPollingException.cs +++ b/src/NetMQ/ErrorPollingException.cs @@ -7,7 +7,7 @@ namespace NetMQ /// ErrorPollingException is an Exception that had been used within the message-queueing system to signal polling-related errors. /// Use one of the NetMQException-derived exception classes instead. /// - [Obsolete] + [Obsolete("This exception is unused in NetMQ and will be removed in NetMQ 4.0.")] public class ErrorPollingException : Exception { /// diff --git a/src/NetMQ/IOutgoingSocket.cs b/src/NetMQ/IOutgoingSocket.cs index 3a2aabd..39e72f4 100644 --- a/src/NetMQ/IOutgoingSocket.cs +++ b/src/NetMQ/IOutgoingSocket.cs @@ -14,7 +14,7 @@ public interface IOutgoingSocket /// the Msg struct that contains the data and the options for this transmission /// a SendReceiveOptions value that can specify the DontWait or SendMore bits (or None) /// The send operation timed out. - [Obsolete("Use Send(ref Msg, bool) or TrySend(ref Msg,TimeSpan, bool) instead.")] + [Obsolete("Use Send(ref Msg, bool) or TrySend(ref Msg,TimeSpan, bool) instead. This will be removed in NetMQ 4.0.")] void Send(ref Msg msg, SendReceiveOptions options); /// diff --git a/src/NetMQ/IReceivingSocket.cs b/src/NetMQ/IReceivingSocket.cs index abf5378..84d95ca 100644 --- a/src/NetMQ/IReceivingSocket.cs +++ b/src/NetMQ/IReceivingSocket.cs @@ -36,7 +36,7 @@ public interface IReceivingSocket /// no sense here and is ignored. /// No message was available within the allowed timeout period. Try again. /// - [Obsolete("Use Receive(ref Msg) or TryReceive(ref Msg,TimeSpan) instead.")] + [Obsolete("Use Receive(ref Msg) or TryReceive(ref Msg,TimeSpan) instead. This will be removed in NetMQ 4.0.")] void Receive(ref Msg msg, SendReceiveOptions options); /// diff --git a/src/NetMQ/InProcActors/Actor.cs b/src/NetMQ/InProcActors/Actor.cs index 6e78f81..c67ebf7 100644 --- a/src/NetMQ/InProcActors/Actor.cs +++ b/src/NetMQ/InProcActors/Actor.cs @@ -10,7 +10,7 @@ namespace NetMQ.Actors /// A NetMQActorEventArgs is an EventArgs that also provides an generically-typed Actor property. /// /// - [Obsolete("Use non generic NetMQActor")] + [Obsolete("Use non generic NetMQActor. This will be removed in NetMQ 4.0.")] public class NetMQActorEventArgs : EventArgs { /// @@ -34,7 +34,7 @@ public NetMQActorEventArgs([NotNull] Actor actor) /// the actor may be passed messages, that are sent to the other end of the pipe /// which I am calling the "shim" /// - [Obsolete("Use non generic NetMQActor")] + [Obsolete("Use non generic NetMQActor. This will be removed in NetMQ 4.0.")] public class Actor : IOutgoingSocket, IReceivingSocket, ISocketPollable, IDisposable { private static readonly Random s_rand = new Random(); @@ -207,7 +207,7 @@ public void Dispose() /// The socket has been stopped. /// is not initialised. /// The send operation timed out. - [Obsolete("Use Send(ref Msg,bool) or TrySend(ref Msg,TimeSpan,bool) instead.")] + [Obsolete("Use Send(ref Msg,bool) or TrySend(ref Msg,TimeSpan,bool) instead. This will be removed in NetMQ 4.0.")] public void Send(ref Msg msg, SendReceiveOptions options) { m_self.Send(ref msg, options); diff --git a/src/NetMQ/InProcActors/IShimHandler.cs b/src/NetMQ/InProcActors/IShimHandler.cs index 17e4c22..5114388 100644 --- a/src/NetMQ/InProcActors/IShimHandler.cs +++ b/src/NetMQ/InProcActors/IShimHandler.cs @@ -9,7 +9,7 @@ namespace NetMQ.InProcActors /// T is the initial state that the Actor will provide. /// This interface specifies the methods Initialize and RunPipeline. /// - [Obsolete("Use non generic NetMQActor and IShimHandler")] + [Obsolete("Use non generic NetMQActor and IShimHandler. This will be removed in NetMQ 4.0.")] public interface IShimHandler { /// diff --git a/src/NetMQ/InProcActors/KnownMessages.cs b/src/NetMQ/InProcActors/KnownMessages.cs index 3649d94..e75c088 100644 --- a/src/NetMQ/InProcActors/KnownMessages.cs +++ b/src/NetMQ/InProcActors/KnownMessages.cs @@ -5,13 +5,13 @@ namespace NetMQ.InProcActors /// /// This was a class intended to hold constant strings that represented fixed, standard Actor messages. /// - [Obsolete("Use NetMQActor.EndShimMessage")] + [Obsolete("Use NetMQActor.EndShimMessage. This will be removed in NetMQ 4.0.")] public class ActorKnownMessages { /// /// This known-actor message was a signal to terminate the pipe. /// - [Obsolete("Use NetMQActor.EndShimMessage")] + [Obsolete("Use NetMQActor.EndShimMessage. This will be removed in NetMQ 4.0.")] public const string END_PIPE = "endPipe"; } } diff --git a/src/NetMQ/InProcActors/Shim.cs b/src/NetMQ/InProcActors/Shim.cs index e8197cf..42b7570 100644 --- a/src/NetMQ/InProcActors/Shim.cs +++ b/src/NetMQ/InProcActors/Shim.cs @@ -8,7 +8,7 @@ namespace NetMQ.InProcActors /// to be supplied with a IShimHandlerOfT that it would use for running the pipe /// protocol with the original Actor PairSocket at the other end of the pipe /// - [Obsolete("Use non generic NetMQActor and IShimHandler")] + [Obsolete("Use non generic NetMQActor and IShimHandler. This will be removed in NetMQ 4.0.")] public class Shim { /// diff --git a/src/NetMQ/Monitoring/NetMQMonitor.cs b/src/NetMQ/Monitoring/NetMQMonitor.cs index 3e324a2..302dcdb 100644 --- a/src/NetMQ/Monitoring/NetMQMonitor.cs +++ b/src/NetMQ/Monitoring/NetMQMonitor.cs @@ -29,12 +29,12 @@ public class NetMQMonitor : IDisposable private readonly ManualResetEvent m_isStoppedEvent = new ManualResetEvent(true); - [Obsolete("Use overload that takes SocketEvents (plural)")] + [Obsolete("Use overload that takes SocketEvents (plural). This will be removed in NetMQ 4.0.")] public NetMQMonitor([NotNull] NetMQContext context, [NotNull] NetMQSocket monitoredSocket, [NotNull] string endpoint, SocketEvent eventsToMonitor) : this(context, monitoredSocket, endpoint, (SocketEvents)eventsToMonitor) {} - [Obsolete("Use non context version")] + [Obsolete("Use non context version. This will be removed in NetMQ 4.0.")] public NetMQMonitor([NotNull] NetMQContext context, [NotNull] NetMQSocket monitoredSocket, [NotNull] string endpoint, SocketEvents eventsToMonitor) { Endpoint = endpoint; diff --git a/src/NetMQ/Msg.cs b/src/NetMQ/Msg.cs index 1152c1c..d656cf9 100644 --- a/src/NetMQ/Msg.cs +++ b/src/NetMQ/Msg.cs @@ -46,7 +46,7 @@ public enum MsgFlags : byte public enum MsgType : byte { /// The has not yet been initialised. - [Obsolete("Use Uninitialised instead")] + [Obsolete("Use Uninitialised instead. This will be removed in NetMQ 4.0.")] Invalid = 0, /// The has not yet been initialised (default value). @@ -56,7 +56,7 @@ public enum MsgType : byte Empty = 101, /// The minimum valid enum value. - [Obsolete] + [Obsolete("This will be removed in NetMQ 4.0.")] Min = 101, /// The data will be garbage collected when no longer needed. @@ -73,7 +73,7 @@ public enum MsgType : byte Delimiter = 104, /// The maximum valid enum value. - [Obsolete] + [Obsolete("This will be removed in NetMQ 4.0.")] Max = 104 } @@ -193,7 +193,7 @@ public void ResetFlags(MsgFlags flags) public byte[] Data { get; private set; } /// Get whether this is initialised and ready for use. - [Obsolete("Use the IsInitialised property instead")] + [Obsolete("Use the IsInitialised property instead. This will be removed in NetMQ 4.0.")] public bool Check() { return IsInitialised; diff --git a/src/NetMQ/NetMQActor.cs b/src/NetMQ/NetMQActor.cs index c0cc140..50ad3e9 100644 --- a/src/NetMQ/NetMQActor.cs +++ b/src/NetMQ/NetMQActor.cs @@ -234,7 +234,7 @@ public static NetMQActor Create([NotNull] ShimAction action) /// the context for this actor to live within /// an IShimHandler that provides the Run method /// the newly-created NetMQActor - [Obsolete("Use non context version")] + [Obsolete("Use non context version. This will be removed in NetMQ 4.0.")] [NotNull] public static NetMQActor Create([NotNull] NetMQContext context, [NotNull] IShimHandler shimHandler) { @@ -248,7 +248,7 @@ public static NetMQActor Create([NotNull] NetMQContext context, [NotNull] IShimH /// a ShimAction - delegate for the action to perfrom /// the state-information - of the generic type T /// the newly-created NetMQActor - [Obsolete("Use non context version")] + [Obsolete("Use non context version. This will be removed in NetMQ 4.0.")] [NotNull] public static NetMQActor Create([NotNull] NetMQContext context, [NotNull] ShimAction action, T state) { @@ -261,7 +261,7 @@ public static NetMQActor Create([NotNull] NetMQContext context, [NotNull] Shi /// the context for this actor to live within /// a ShimAction - delegate for the action to perform /// the newly-created NetMQActor - [Obsolete("Use non context version")] + [Obsolete("Use non context version. This will be removed in NetMQ 4.0.")] [NotNull] public static NetMQActor Create([NotNull] NetMQContext context, [NotNull] ShimAction action) { @@ -297,7 +297,7 @@ private void RunShim() /// The socket has been stopped. /// is not initialised. /// The send operation timed out. - [Obsolete("Use Send(ref Msg,bool) or TrySend(ref Msg,TimeSpan,bool) instead.")] + [Obsolete("Use Send(ref Msg,bool) or TrySend(ref Msg,TimeSpan,bool) instead. This will be removed in NetMQ 4.0.")] public void Send(ref Msg msg, SendReceiveOptions options) { m_self.Send(ref msg, options); @@ -321,7 +321,7 @@ public bool TrySend(ref Msg msg, TimeSpan timeout, bool more) #region IReceivingSocket /// The receive operation timed out. - [Obsolete("Use Receive(ref Msg) or TryReceive(ref Msg,TimeSpan) instead.")] + [Obsolete("Use Receive(ref Msg) or TryReceive(ref Msg,TimeSpan) instead. This will be removed in NetMQ 4.0.")] public void Receive(ref Msg msg, SendReceiveOptions options) { m_self.Receive(ref msg, options); diff --git a/src/NetMQ/NetMQBeacon.cs b/src/NetMQ/NetMQBeacon.cs index 25608fb..8fe6e66 100644 --- a/src/NetMQ/NetMQBeacon.cs +++ b/src/NetMQ/NetMQBeacon.cs @@ -260,7 +260,7 @@ private NetMQFrame ReceiveUdpFrame(out string peerName) /// Create a new NetMQBeacon, contained within the given context. /// /// the NetMQContext to contain this new socket - [Obsolete("Use non context version")] + [Obsolete("Use non context version. This will be removed in NetMQ 4.0.")] public NetMQBeacon([NotNull] NetMQContext context) { m_actor = NetMQActor.Create(context, new Shim()); diff --git a/src/NetMQ/NetMQContext.cs b/src/NetMQ/NetMQContext.cs index f9caade..6889de5 100644 --- a/src/NetMQ/NetMQContext.cs +++ b/src/NetMQ/NetMQContext.cs @@ -27,7 +27,7 @@ namespace NetMQ /// /// You should create and use exactly one context in your process. /// - [Obsolete("NetMQContext is obsolete, you can create sockets with new keyword, like new DealerSocket")] + [Obsolete("NetMQContext is obsolete, you can create sockets with new keyword, like new DealerSocket. This will be removed in NetMQ 4.0.")] public class NetMQContext : IDisposable { private readonly Ctx m_ctx; diff --git a/src/NetMQ/NetMQException.cs b/src/NetMQ/NetMQException.cs index 82a23a7..209124a 100644 --- a/src/NetMQ/NetMQException.cs +++ b/src/NetMQ/NetMQException.cs @@ -242,7 +242,7 @@ protected EndpointNotFoundException(SerializationInfo info, StreamingContext con /// and is raised within Sub.XSetSocketOption if sending the queued-message fails. /// [Serializable] - [Obsolete("AgainException is obsolete. Use TrySendFrame or TryReceive return values instead of catching this exception.")] + [Obsolete("AgainException is obsolete. Use TrySendFrame or TryReceive return values instead of catching this exception. This will be removed in NetMQ 4.0.")] public class AgainException : NetMQException { /// diff --git a/src/NetMQ/NetMQMessage.cs b/src/NetMQ/NetMQMessage.cs index 52f51b8..ec36618 100644 --- a/src/NetMQ/NetMQMessage.cs +++ b/src/NetMQ/NetMQMessage.cs @@ -185,7 +185,7 @@ public void Append(long value) /// Add the Data of the given Blob, as a new frame, onto this NetMQMessage. /// /// the Blob whose data is to be added as a new frame - [Obsolete("Use NetMQFrame instead of blobs")] + [Obsolete("Use NetMQFrame instead of blobs. This will be removed in NetMQ 4.0.")] public void Append([NotNull] Blob blob) { Append(blob.Data); @@ -303,7 +303,7 @@ public void Push(long value) /// the collection of frames of this NetMQMessage, /// pushing all of the other frames upward in index-position. /// - [Obsolete("Use NetMQFrame instead of blobs")] + [Obsolete("Use NetMQFrame instead of blobs. This will be removed in NetMQ 4.0.")] public void Push([NotNull] Blob blob) { Push(blob.Data); diff --git a/src/NetMQ/NetMQScheduler.cs b/src/NetMQ/NetMQScheduler.cs index 59c2b6f..b11b7be 100644 --- a/src/NetMQ/NetMQScheduler.cs +++ b/src/NetMQ/NetMQScheduler.cs @@ -9,7 +9,7 @@ namespace NetMQ { - [Obsolete("Use NetMQPoller instead")] + [Obsolete("Use NetMQPoller instead. This will be removed in NetMQ 4.0.")] public class NetMQScheduler : TaskScheduler, IDisposable { private static int s_schedulerCounter; @@ -38,7 +38,7 @@ public class NetMQScheduler : TaskScheduler, IDisposable /// /// the NetMQContext to create this NetMQScheduler within /// (optional)the Poller for this Net to use - [Obsolete("Use non context version")] + [Obsolete("Use non context version. This will be removed in NetMQ 4.0.")] public NetMQScheduler([NotNull] NetMQContext context, [CanBeNull] Poller poller = null) : this(poller, context.CreatePushSocket(), context.CreatePullSocket()) { diff --git a/src/NetMQ/NetMQSocket.cs b/src/NetMQ/NetMQSocket.cs index 57d0311..598d834 100644 --- a/src/NetMQ/NetMQSocket.cs +++ b/src/NetMQ/NetMQSocket.cs @@ -367,7 +367,7 @@ internal void InvokeEvents(object sender, PollEvents events) /// Either , or . /// is ignored. /// The receive operation timed out. - [Obsolete("Use Receive(ref Msg) or TryReceive(ref Msg,TimeSpan) instead.")] + [Obsolete("Use Receive(ref Msg) or TryReceive(ref Msg,TimeSpan) instead. This will be removed in NetMQ 4.0.")] public virtual void Receive(ref Msg msg, SendReceiveOptions options) { // This legacy method adapts the newer nothrow API to the older AgainException one. @@ -410,7 +410,7 @@ public virtual bool TryReceive(ref Msg msg, TimeSpan timeout) /// The socket has been stopped. /// is not initialised. /// The send operation timed out. - [Obsolete("Use Send(ref Msg, bool) or TrySend(ref Msg,TimeSpan, bool) instead.")] + [Obsolete("Use Send(ref Msg, bool) or TrySend(ref Msg,TimeSpan, bool) instead. This will be removed in NetMQ 4.0.")] public virtual void Send(ref Msg msg, SendReceiveOptions options) { bool more = (options & SendReceiveOptions.SendMore) != 0; @@ -456,7 +456,7 @@ public virtual bool TrySend(ref Msg msg, TimeSpan timeout, bool more) /// A topic is simply a specific prefix (in the form of a byte-array or the equivalent text). /// This is valid only for Subscriber and XSubscriber sockets. /// - [Obsolete("Do not use this method if the socket is different from Subscriber and XSubscriber")] + [Obsolete("Do not use this method if the socket is different from Subscriber and XSubscriber. This will be removed in NetMQ 4.0.")] public virtual void Subscribe(string topic) { SetSocketOption(ZmqSocketOption.Subscribe, topic); @@ -471,7 +471,7 @@ public virtual void Subscribe(string topic) /// A topic is simply a specific prefix (in the form of a byte-array or the equivalent text). /// This is valid only for Subscriber and XSubscriber sockets. /// - [Obsolete("Do not use this method if the socket is different from Subscriber and XSubscriber")] + [Obsolete("Do not use this method if the socket is different from Subscriber and XSubscriber. This will be removed in NetMQ 4.0.")] public virtual void Subscribe(byte[] topic) { SetSocketOption(ZmqSocketOption.Subscribe, topic); @@ -486,7 +486,7 @@ public virtual void Subscribe(byte[] topic) /// messages of that topic. A topic is simply a specific prefix (in the form of a byte-array or the equivalent text). /// This is valid only for Subscriber and XSubscriber sockets. /// - [Obsolete("Do not use this method if the socket is different from Subscriber and XSubscriber")] + [Obsolete("Do not use this method if the socket is different from Subscriber and XSubscriber. This will be removed in NetMQ 4.0.")] public virtual void Unsubscribe(string topic) { SetSocketOption(ZmqSocketOption.Unsubscribe, topic); @@ -501,7 +501,7 @@ public virtual void Unsubscribe(string topic) /// messages of that topic. A topic is simply a specific prefix (in the form of a byte-array or the equivalent text). /// This is valid only for Subscriber and XSubscriber sockets. /// - [Obsolete("Do not use this method if the socket is different from Subscriber and XSubscriber")] + [Obsolete("Do not use this method if the socket is different from Subscriber and XSubscriber. This will be removed in NetMQ 4.0.")] public virtual void Unsubscribe(byte[] topic) { SetSocketOption(ZmqSocketOption.Unsubscribe, topic); @@ -520,7 +520,7 @@ public virtual void Unsubscribe(byte[] topic) /// The protocol of is not supported. /// The socket has been stopped. /// Maximum number of sockets reached. - [Obsolete("Use overload that accepts SocketEvents (plural) instead")] + [Obsolete("Use overload that accepts SocketEvents (plural) instead. This will be removed in NetMQ 4.0.")] public void Monitor([NotNull] string endpoint, SocketEvent events = SocketEvent.All) { Monitor(endpoint, (SocketEvents)events); diff --git a/src/NetMQ/NetMQSocketEventArgs.cs b/src/NetMQ/NetMQSocketEventArgs.cs index 28b5c24..8228d70 100644 --- a/src/NetMQ/NetMQSocketEventArgs.cs +++ b/src/NetMQ/NetMQSocketEventArgs.cs @@ -47,7 +47,7 @@ internal void Init(PollEvents events) /// /// Get whether at least one message may be received by the socket without blocking. /// - [Obsolete("Use IsReadyToReceive")] + [Obsolete("Use IsReadyToReceive. This will be removed in NetMQ 4.0.")] public bool ReceiveReady { get { return IsReadyToReceive; } @@ -57,7 +57,7 @@ public bool ReceiveReady /// /// Get whether at least one message may be sent by the socket without blocking. /// - [Obsolete("Use IsReadyToSend")] + [Obsolete("Use IsReadyToSend. This will be removed in NetMQ 4.0.")] public bool SendReady { get { return IsReadyToSend; } diff --git a/src/NetMQ/OutgoingSocketExtensions.cs b/src/NetMQ/OutgoingSocketExtensions.cs index c338318..7b84fed 100644 --- a/src/NetMQ/OutgoingSocketExtensions.cs +++ b/src/NetMQ/OutgoingSocketExtensions.cs @@ -177,7 +177,7 @@ public static bool TrySendFrame([NotNull] this IOutgoingSocket socket, [NotNull] /// the byte-array of data to send /// the number of bytes to send from . /// options to control how the data is sent - [Obsolete("Use SendFrame or TrySendFrame")] + [Obsolete("Use SendFrame or TrySendFrame. This will be removed in NetMQ 4.0.")] public static void Send([NotNull] this IOutgoingSocket socket, [NotNull] byte[] data, int length, SendReceiveOptions options) { var msg = new Msg(); @@ -198,7 +198,7 @@ public static void Send([NotNull] this IOutgoingSocket socket, [NotNull] byte[] /// the number of bytes to send /// if true, return immediately without waiting for the send operation to complete (optional: default is false) /// set this flag to true to signal that you will be immediately sending another message (optional: default is false) - [Obsolete("Use SendFrame or TrySendFrame")] + [Obsolete("Use SendFrame or TrySendFrame. This will be removed in NetMQ 4.0.")] public static void Send([NotNull] this IOutgoingSocket socket, [NotNull] byte[] data, int length, bool dontWait = false, bool sendMore = false) { var options = SendReceiveOptions.None; @@ -221,7 +221,7 @@ public static void Send([NotNull] this IOutgoingSocket socket, [NotNull] byte[] /// /// the IOutgoingSocket to transmit on /// the byte-array of data to send - [Obsolete("Use SendFrame or TrySendFrame")] + [Obsolete("Use SendFrame or TrySendFrame. This will be removed in NetMQ 4.0.")] public static void Send([NotNull] this IOutgoingSocket socket, [NotNull] byte[] data) { socket.Send(data, data.Length); @@ -236,7 +236,7 @@ public static void Send([NotNull] this IOutgoingSocket socket, [NotNull] byte[] /// if true, return immediately without waiting for the send operation to complete (optional: default is false) /// a reference to this IOutgoingSocket so that method-calls may be chained together [NotNull] - [Obsolete("Use SendMoreFrame or TrySendFrame")] + [Obsolete("Use SendMoreFrame or TrySendFrame. This will be removed in NetMQ 4.0.")] public static IOutgoingSocket SendMore([NotNull] this IOutgoingSocket socket, [NotNull] byte[] data, bool dontWait = false) { socket.Send(data, data.Length, dontWait, true); @@ -253,7 +253,7 @@ public static IOutgoingSocket SendMore([NotNull] this IOutgoingSocket socket, [N /// if true, return immediately without waiting for the send operation to complete (optional: default is false) /// a reference to this IOutgoingSocket so that method-calls may be chained together [NotNull] - [Obsolete("Use SendMoreFrame or TrySendFrame")] + [Obsolete("Use SendMoreFrame or TrySendFrame. This will be removed in NetMQ 4.0.")] public static IOutgoingSocket SendMore([NotNull] this IOutgoingSocket socket, [NotNull] byte[] data, int length, bool dontWait = false) { socket.Send(data, length, dontWait, true); @@ -525,7 +525,7 @@ public static bool TrySendFrame([NotNull] this IOutgoingSocket socket, [NotNull] /// a string containing the message to send /// the Encoding to use when converting the message-string into bytes /// use this to specify which of the DontWait and SendMore flags to set - [Obsolete("Use SendFrame or TrySendFrame")] + [Obsolete("Use SendFrame or TrySendFrame. This will be removed in NetMQ 4.0.")] public static void Send([NotNull] this IOutgoingSocket socket, [NotNull] string message, [NotNull] Encoding encoding, SendReceiveOptions options) { var msg = new Msg(); @@ -552,7 +552,7 @@ public static void Send([NotNull] this IOutgoingSocket socket, [NotNull] string /// the Encoding to use when converting the message-string into bytes /// if true, return immediately without waiting for the send operation to complete (optional: default is false) /// set this flag to true to signal that you will be immediately sending another message (optional: default is false) - [Obsolete("Use SendFrame or TrySendFrame")] + [Obsolete("Use SendFrame or TrySendFrame. This will be removed in NetMQ 4.0.")] public static void Send([NotNull] this IOutgoingSocket socket, [NotNull] string message, [NotNull] Encoding encoding, bool dontWait = false, bool sendMore = false) { var options = SendReceiveOptions.None; @@ -577,7 +577,7 @@ public static void Send([NotNull] this IOutgoingSocket socket, [NotNull] string /// a string containing the message to send /// if true, return immediately without waiting for the send operation to complete (optional: default is false) /// set this flag to true to signal that you will be immediately sending another message (optional: default is false) - [Obsolete("Use SendFrame or TrySendFrame")] + [Obsolete("Use SendFrame or TrySendFrame. This will be removed in NetMQ 4.0.")] public static void Send([NotNull] this IOutgoingSocket socket, [NotNull] string message, bool dontWait = false, bool sendMore = false) { Send(socket, message, Encoding.ASCII, dontWait, sendMore); @@ -592,7 +592,7 @@ public static void Send([NotNull] this IOutgoingSocket socket, [NotNull] string /// if true, return immediately without waiting for the send operation to complete /// a reference to this IOutgoingSocket so that method-calls may be chained together [NotNull] - [Obsolete("Use SendMoreFrame or TrySendFrame")] + [Obsolete("Use SendMoreFrame or TrySendFrame. This will be removed in NetMQ 4.0.")] public static IOutgoingSocket SendMore([NotNull] this IOutgoingSocket socket, [NotNull] string message, bool dontWait = false) { socket.Send(message, dontWait, true); @@ -609,7 +609,7 @@ public static IOutgoingSocket SendMore([NotNull] this IOutgoingSocket socket, [N /// if true, return immediately without waiting for the send operation to complete (optional: default is false) /// a reference to this IOutgoingSocket so that method-calls may be chained together [NotNull] - [Obsolete("Use SendMoreFrame or TrySendFrame")] + [Obsolete("Use SendMoreFrame or TrySendFrame. This will be removed in NetMQ 4.0.")] public static IOutgoingSocket SendMore([NotNull] this IOutgoingSocket socket, [NotNull] string message, [NotNull] Encoding encoding, bool dontWait = false) { socket.Send(message, encoding, dontWait, true); @@ -704,7 +704,7 @@ public static bool TrySendMultipartMessage([NotNull] this IOutgoingSocket socket /// the IOutgoingSocket to transmit on /// the NetMQMessage that contains the frames of data to send /// if true, return immediately without waiting for the send operation to complete (optional: default is false) - [Obsolete("Use TrySendMultipartMessage or SendMultipartMessage")] + [Obsolete("Use TrySendMultipartMessage or SendMultipartMessage. This will be removed in NetMQ 4.0.")] public static void SendMessage([NotNull] this IOutgoingSocket socket, [NotNull] NetMQMessage message, bool dontWait = false) { for (int i = 0; i < message.FrameCount - 1; i++) diff --git a/src/NetMQ/Poller.cs b/src/NetMQ/Poller.cs index 7164ea8..8db71b7 100644 --- a/src/NetMQ/Poller.cs +++ b/src/NetMQ/Poller.cs @@ -12,7 +12,7 @@ namespace NetMQ /// The Poller class provides for managing a set of one or more sockets and being alerted when one of them has a message /// ready. /// - [Obsolete("Use NetMQPoller instead")] + [Obsolete("Use NetMQPoller instead. This will be removed in NetMQ 4.0.")] public class Poller : INetMQPoller, ISocketPollableCollection, IDisposable { /// @@ -367,7 +367,7 @@ public void PollTillCancelledNonBlocking() /// /// Poll till Cancel or CancelAndJoin is called. This is a blocking method. /// - [Obsolete("Use PollTillCancelled instead")] + [Obsolete("Use PollTillCancelled instead. This will be removed in NetMQ 4.0.")] public void Start() { PollTillCancelled(); @@ -378,7 +378,7 @@ public void Start() /// If it doesn't stop within 20 seconds, it times-out anyway and returns. /// /// if true, this method will block until the poller is fully stopped - [Obsolete("Use Cancel(if your argument was false) or CancelAndJoin (if your argument was true)")] + [Obsolete("Use Cancel(if your argument was false) or CancelAndJoin (if your argument was true). This will be removed in NetMQ 4.0.")] public void Stop(bool waitForCloseToComplete) { Cancel(waitForCloseToComplete); @@ -388,7 +388,7 @@ public void Stop(bool waitForCloseToComplete) /// Stop the poller job. This returns after waiting for that thread to stop. /// This is equivalent to calling CancelAndJoin. /// - [Obsolete("Use CancelAndJoin")] + [Obsolete("Use CancelAndJoin. This will be removed in NetMQ 4.0.")] public void Stop() { Cancel(true); diff --git a/src/NetMQ/ReceivingSocketExtensions.cs b/src/NetMQ/ReceivingSocketExtensions.cs index ab933af..2473f98 100644 --- a/src/NetMQ/ReceivingSocketExtensions.cs +++ b/src/NetMQ/ReceivingSocketExtensions.cs @@ -21,11 +21,11 @@ public static class ReceivingSocketExtensions /// The used in string related methods that do /// not explicitly provide an encoding parameter. /// - [Obsolete("Use SendReceiveConstans.DefaultEncoding instead")] + [Obsolete("Use SendReceiveConstans.DefaultEncoding instead. This will be removed in NetMQ 4.0.")] public static readonly Encoding DefaultEncoding = Encoding.UTF8; /// Indicates an infinite timeout for receive operations. - [Obsolete("Use SendReceiveConstans.InfiniteTimeout instead")] + [Obsolete("Use SendReceiveConstans.InfiniteTimeout instead. This will be removed in NetMQ 4.0.")] public static readonly TimeSpan InfiniteTimeout = TimeSpan.FromMilliseconds(-1); /// @@ -172,7 +172,7 @@ public static bool TryReceiveFrameBytes([NotNull] this IReceivingSocket socket, /// The message's data as a newly allocated array of bytes. /// If is a and elapsed. [NotNull] - [Obsolete("Use ReceiveFrameBytes or TryReceiveFrameBytes instead.")] + [Obsolete("Use ReceiveFrameBytes or TryReceiveFrameBytes instead. This will be removed in NetMQ 4.0.")] public static byte[] Receive([NotNull] this IReceivingSocket socket) { bool hasMore; @@ -187,7 +187,7 @@ public static byte[] Receive([NotNull] this IReceivingSocket socket) /// The message's data as a newly allocated array of bytes. /// If is a and elapsed. [NotNull] - [Obsolete("Use ReceiveFrameBytes or TryReceiveFrameBytes instead.")] + [Obsolete("Use ReceiveFrameBytes or TryReceiveFrameBytes instead. This will be removed in NetMQ 4.0.")] public static byte[] Receive([NotNull] this IReceivingSocket socket, out bool hasMore) { return socket.Receive(SendReceiveOptions.None, out hasMore); @@ -202,7 +202,7 @@ public static byte[] Receive([NotNull] this IReceivingSocket socket, out bool ha /// The message's data as a newly allocated array of bytes. /// If is a and elapsed. [NotNull] - [Obsolete("Use ReceiveFrameBytes or TryReceiveFrameBytes instead.")] + [Obsolete("Use ReceiveFrameBytes or TryReceiveFrameBytes instead. This will be removed in NetMQ 4.0.")] public static byte[] Receive([NotNull] this IReceivingSocket socket, bool dontWait, out bool hasMore) { return socket.Receive(dontWait ? SendReceiveOptions.DontWait : SendReceiveOptions.None, out hasMore); @@ -216,7 +216,7 @@ public static byte[] Receive([NotNull] this IReceivingSocket socket, bool dontWa /// The message's data as a newly allocated array of bytes. /// If is a and elapsed. [NotNull] - [Obsolete("Use ReceiveFrameBytes or TryReceiveFrameBytes instead.")] + [Obsolete("Use ReceiveFrameBytes or TryReceiveFrameBytes instead. This will be removed in NetMQ 4.0.")] public static byte[] Receive([NotNull] this IReceivingSocket socket, SendReceiveOptions options) { bool hasMore; @@ -232,7 +232,7 @@ public static byte[] Receive([NotNull] this IReceivingSocket socket, SendReceive /// The message's data as a newly allocated array of bytes. /// No message was available within the allowed timeout period. Try again. [NotNull] - [Obsolete("Use ReceiveFrameBytes or TryReceiveFrameBytes instead.")] + [Obsolete("Use ReceiveFrameBytes or TryReceiveFrameBytes instead. This will be removed in NetMQ 4.0.")] public static byte[] Receive([NotNull] this IReceivingSocket socket, SendReceiveOptions options, out bool hasMore) { var msg = new Msg(); @@ -259,7 +259,7 @@ public static byte[] Receive([NotNull] this IReceivingSocket socket, SendReceive /// The internal select operation failed. /// has been stopped. [CanBeNull] - [Obsolete("Use ReceiveFrameBytes or TryReceiveFrameBytes instead.")] + [Obsolete("Use ReceiveFrameBytes or TryReceiveFrameBytes instead. This will be removed in NetMQ 4.0.")] public static byte[] Receive([NotNull] this NetMQSocket socket, TimeSpan timeout) { var result = socket.Poll(PollEvents.PollIn, timeout); @@ -389,7 +389,7 @@ public static bool TryReceiveMultipartBytes([NotNull] this IReceivingSocket sock /// an extra allocation will occur, but the result will still be correct. /// A list of all frames of the next message, each as an array of bytes. /// If is a and elapsed. - [Obsolete("Use ReceiveMultipartBytes or TryReceiveMultipartBytes instead")] + [Obsolete("Use ReceiveMultipartBytes or TryReceiveMultipartBytes instead. This will be removed in NetMQ 4.0.")] [NotNull] [ItemNotNull] public static List ReceiveMessages([NotNull] this IReceivingSocket socket, int expectedFrameCount = 4) @@ -411,7 +411,7 @@ public static List ReceiveMessages([NotNull] this IReceivingSocket socke /// an extra allocation will occur, but the result will still be correct. /// A list of all frames of the next message, each as an array of bytes. /// If is a and elapsed. - [Obsolete("Use ReceiveMultipartBytes or TryReceiveMultipartBytes instead")] + [Obsolete("Use ReceiveMultipartBytes or TryReceiveMultipartBytes instead. This will be removed in NetMQ 4.0.")] [NotNull] [ItemNotNull] public static List ReceiveAll([NotNull] this IReceivingSocket socket, int expectedFrameCount = 4) @@ -646,7 +646,7 @@ public static bool TryReceiveFrameString([NotNull] this IReceivingSocket socket, /// No message was available within the allowed timeout period. Try again. /// [NotNull] - [Obsolete("Use ReceiveFrameString or TryReceiveFrameString methods instead")] + [Obsolete("Use ReceiveFrameString or TryReceiveFrameString methods instead. This will be removed in NetMQ 4.0.")] public static string ReceiveString([NotNull] this IReceivingSocket socket, [NotNull] Encoding encoding, SendReceiveOptions options, out bool hasMore) { if (encoding == null) @@ -679,7 +679,7 @@ public static string ReceiveString([NotNull] this IReceivingSocket socket, [NotN /// If is a and /// elapsed. [NotNull] - [Obsolete("Use ReceiveFrameString or TryReceiveFrameString methods instead")] + [Obsolete("Use ReceiveFrameString or TryReceiveFrameString methods instead. This will be removed in NetMQ 4.0.")] public static string ReceiveString([NotNull] this IReceivingSocket socket, SendReceiveOptions options, out bool hasMore) { return socket.ReceiveString(Encoding.ASCII, options, out hasMore); @@ -695,7 +695,7 @@ public static string ReceiveString([NotNull] this IReceivingSocket socket, SendR /// If is a and /// elapsed. [NotNull] - [Obsolete("Use ReceiveFrameString or TryReceiveFrameString methods instead")] + [Obsolete("Use ReceiveFrameString or TryReceiveFrameString methods instead. This will be removed in NetMQ 4.0.")] public static string ReceiveString([NotNull] this IReceivingSocket socket, SendReceiveOptions options) { bool hasMore; @@ -713,7 +713,7 @@ public static string ReceiveString([NotNull] this IReceivingSocket socket, SendR /// If is a and /// elapsed. [NotNull] - [Obsolete("Use ReceiveFrameString or TryReceiveFrameString methods instead")] + [Obsolete("Use ReceiveFrameString or TryReceiveFrameString methods instead. This will be removed in NetMQ 4.0.")] public static string ReceiveString([NotNull] this IReceivingSocket socket, [NotNull] Encoding encoding, SendReceiveOptions options) { bool hasMore; @@ -732,7 +732,7 @@ public static string ReceiveString([NotNull] this IReceivingSocket socket, [NotN /// If is a and /// elapsed. [NotNull] - [Obsolete("Use ReceiveFrameString or TryReceiveFrameString methods instead")] + [Obsolete("Use ReceiveFrameString or TryReceiveFrameString methods instead. This will be removed in NetMQ 4.0.")] public static string ReceiveString([NotNull] this IReceivingSocket socket, bool dontWait, out bool hasMore) { return ReceiveString(socket, Encoding.ASCII, dontWait ? SendReceiveOptions.DontWait : SendReceiveOptions.None, out hasMore); @@ -751,7 +751,7 @@ public static string ReceiveString([NotNull] this IReceivingSocket socket, bool /// If is a and /// elapsed. [NotNull] - [Obsolete("Use ReceiveFrameString or TryReceiveFrameString methods instead")] + [Obsolete("Use ReceiveFrameString or TryReceiveFrameString methods instead. This will be removed in NetMQ 4.0.")] public static string ReceiveString([NotNull] this IReceivingSocket socket, [NotNull] Encoding encoding, bool dontWait, out bool hasMore) { return socket.ReceiveString(encoding, dontWait ? SendReceiveOptions.DontWait : SendReceiveOptions.None, out hasMore); @@ -768,7 +768,7 @@ public static string ReceiveString([NotNull] this IReceivingSocket socket, [NotN /// If is a and /// elapsed. [NotNull] - [Obsolete("Use ReceiveFrameString or TryReceiveFrameString methods instead")] + [Obsolete("Use ReceiveFrameString or TryReceiveFrameString methods instead. This will be removed in NetMQ 4.0.")] public static string ReceiveString([NotNull] this IReceivingSocket socket, out bool hasMore) { return socket.ReceiveString(Encoding.ASCII, SendReceiveOptions.None, out hasMore); @@ -786,7 +786,7 @@ public static string ReceiveString([NotNull] this IReceivingSocket socket, out b /// If is a and /// elapsed. [NotNull] - [Obsolete("Use ReceiveFrameString or TryReceiveFrameString methods instead")] + [Obsolete("Use ReceiveFrameString or TryReceiveFrameString methods instead. This will be removed in NetMQ 4.0.")] public static string ReceiveString([NotNull] this IReceivingSocket socket, [NotNull] Encoding encoding, out bool hasMore) { return socket.ReceiveString(encoding, SendReceiveOptions.None, out hasMore); @@ -802,7 +802,7 @@ public static string ReceiveString([NotNull] this IReceivingSocket socket, [NotN /// If is a and /// elapsed. [NotNull] - [Obsolete("Use ReceiveFrameString or TryReceiveFrameString methods instead")] + [Obsolete("Use ReceiveFrameString or TryReceiveFrameString methods instead. This will be removed in NetMQ 4.0.")] public static string ReceiveString([NotNull] this IReceivingSocket socket, [NotNull] Encoding encoding) { bool hasMore; @@ -818,7 +818,7 @@ public static string ReceiveString([NotNull] this IReceivingSocket socket, [NotN /// If is a and /// elapsed. [NotNull] - [Obsolete("Use ReceiveFrameString or TryReceiveFrameString methods instead")] + [Obsolete("Use ReceiveFrameString or TryReceiveFrameString methods instead. This will be removed in NetMQ 4.0.")] public static string ReceiveString([NotNull] this IReceivingSocket socket) { bool hasMore; @@ -839,7 +839,7 @@ public static string ReceiveString([NotNull] this IReceivingSocket socket) /// The internal select operation failed. /// The socket has been stopped. [CanBeNull] - [Obsolete("Use ReceiveFrameString or TryReceiveFrameString methods instead")] + [Obsolete("Use ReceiveFrameString or TryReceiveFrameString methods instead. This will be removed in NetMQ 4.0.")] public static string ReceiveString([NotNull] this NetMQSocket socket, TimeSpan timeout) { return socket.ReceiveString(Encoding.ASCII, timeout); @@ -860,7 +860,7 @@ public static string ReceiveString([NotNull] this NetMQSocket socket, TimeSpan t /// The internal select operation failed. /// The socket has been stopped. [CanBeNull] - [Obsolete("Use ReceiveFrameString or TryReceiveFrameString methods instead")] + [Obsolete("Use ReceiveFrameString or TryReceiveFrameString methods instead. This will be removed in NetMQ 4.0.")] public static string ReceiveString([NotNull] this NetMQSocket socket, [NotNull] Encoding encoding, TimeSpan timeout) { var result = socket.Poll(PollEvents.PollIn, timeout); @@ -1030,7 +1030,7 @@ public static bool TryReceiveMultipartStrings([NotNull] this IReceivingSocket so /// A list of all frames of the next message, decoded as strings. /// If is a and /// elapsed. - [Obsolete("Use ReceiveMultipartStrings or TryReceiveMultipartStrings instead")] + [Obsolete("Use ReceiveMultipartStrings or TryReceiveMultipartStrings instead. This will be removed in NetMQ 4.0.")] [NotNull] [ItemNotNull] public static List ReceiveStringMessages([NotNull] this IReceivingSocket socket, int expectedFrameCount = 4) @@ -1049,7 +1049,7 @@ public static List ReceiveStringMessages([NotNull] this IReceivingSocket /// A list of all frames of the next message, decoded as strings. /// If is a and /// elapsed. - [Obsolete("Use ReceiveMultipartStrings or TryReceiveMultipartStrings instead")] + [Obsolete("Use ReceiveMultipartStrings or TryReceiveMultipartStrings instead. This will be removed in NetMQ 4.0.")] [NotNull] [ItemNotNull] public static List ReceiveStringMessages([NotNull] this IReceivingSocket socket, [NotNull] Encoding encoding, int expectedFrameCount = 4) @@ -1067,7 +1067,7 @@ public static List ReceiveStringMessages([NotNull] this IReceivingSocket /// The socket to receive from. /// If is a and /// elapsed. - [Obsolete("Use ReceiveMultipartStrings or TryReceiveMultipartStrings instead")] + [Obsolete("Use ReceiveMultipartStrings or TryReceiveMultipartStrings instead. This will be removed in NetMQ 4.0.")] [NotNull] [ItemNotNull] public static IList ReceiveAllString([NotNull] this IReceivingSocket socket) @@ -1188,7 +1188,7 @@ public static bool TryReceiveMultipartMessage([NotNull] this IReceivingSocket so /// non-blocking if true and blocking otherwise /// If is a and /// elapsed. - [Obsolete("Use ReceiveMultipartMessage or TryReceiveMultipartMessage instead")] + [Obsolete("Use ReceiveMultipartMessage or TryReceiveMultipartMessage instead. This will be removed in NetMQ 4.0.")] public static void ReceiveMessage([NotNull] this IReceivingSocket socket, [NotNull] NetMQMessage message, bool dontWait = false) { message.Clear(); @@ -1214,7 +1214,7 @@ public static void ReceiveMessage([NotNull] this IReceivingSocket socket, [NotNu /// the received message /// If is a and /// elapsed. - [Obsolete("Use ReceiveMultipartMessage or TryReceiveMultipartMessage instead")] + [Obsolete("Use ReceiveMultipartMessage or TryReceiveMultipartMessage instead. This will be removed in NetMQ 4.0.")] [NotNull] public static NetMQMessage ReceiveMessage([NotNull] this IReceivingSocket socket, bool dontWait = false) { @@ -1233,7 +1233,7 @@ public static NetMQMessage ReceiveMessage([NotNull] this IReceivingSocket socket /// The internal select operation failed. /// If is a and /// elapsed. - [Obsolete("Use ReceiveMultipartMessage or TryReceiveMultipartMessage instead")] + [Obsolete("Use ReceiveMultipartMessage or TryReceiveMultipartMessage instead. This will be removed in NetMQ 4.0.")] [CanBeNull] public static NetMQMessage ReceiveMessage([NotNull] this NetMQSocket socket, TimeSpan timeout) { @@ -1364,7 +1364,7 @@ public static bool TryReceiveSignal([NotNull] this IReceivingSocket socket, Time /// true if that one frame has no bits set other than in the lowest-order byte. /// If is a and /// elapsed. - [Obsolete("User ReceiveSignal or TryReceiveSignal instead")] + [Obsolete("User ReceiveSignal or TryReceiveSignal instead. This will be removed in NetMQ 4.0.")] public static bool WaitForSignal([NotNull] this IReceivingSocket socket) { while (true) diff --git a/src/NetMQ/SendReceiveOptions.cs b/src/NetMQ/SendReceiveOptions.cs index c96e4d6..ab23266 100644 --- a/src/NetMQ/SendReceiveOptions.cs +++ b/src/NetMQ/SendReceiveOptions.cs @@ -8,7 +8,7 @@ namespace NetMQ /// or the SendMore bit, set. /// [Flags] - [Obsolete("New Receive/Send API doesn't use SendReceiveOptions")] + [Obsolete("New Receive/Send API doesn't use SendReceiveOptions. This will be removed in NetMQ 4.0.")] public enum SendReceiveOptions { /// @@ -27,7 +27,7 @@ public enum SendReceiveOptions SendMore = 2, // Deprecated aliases - [Obsolete("Use DontWait instead")] + [Obsolete("Use DontWait instead. This will be removed in NetMQ 4.0.")] NoBlock = DontWait } } \ No newline at end of file diff --git a/src/NetMQ/SocketEvents.cs b/src/NetMQ/SocketEvents.cs index 265e5ba..e068800 100644 --- a/src/NetMQ/SocketEvents.cs +++ b/src/NetMQ/SocketEvents.cs @@ -33,7 +33,7 @@ public enum SocketEvents /// This enum-type specifies socket transport events (TCP and IPC only). /// [Flags] - [Obsolete("Use SocketEvents (plural) instead")] + [Obsolete("Use SocketEvents (plural) instead. This will be removed in NetMQ 4.0.")] public enum SocketEvent { Connected = 1, diff --git a/src/NetMQ/SocketOptions.cs b/src/NetMQ/SocketOptions.cs index f249df5..103358c 100644 --- a/src/NetMQ/SocketOptions.cs +++ b/src/NetMQ/SocketOptions.cs @@ -40,7 +40,7 @@ public long Affinity /// /// Unused. /// - [Obsolete("This property doesn't effect NetMQ anymore")] + [Obsolete("This property doesn't effect NetMQ anymore. This will be removed in NetMQ 4.0.")] public bool CopyMessages { get { return false; } @@ -92,7 +92,7 @@ public int SendBuffer /// Get or set the size of the receive buffer for the specified socket. /// A value of zero means that the OS default is in effect. /// - [Obsolete("Use ReceiveBuffer instead")] + [Obsolete("Use ReceiveBuffer instead. This will be removed in NetMQ 4.0.")] public int ReceivevBuffer { get { return ReceiveBuffer; } @@ -236,7 +236,7 @@ public int MulticastHops /// /// Get or set the amount of time after which a synchronous receive call will time out. /// - [Obsolete("Pass a TimeSpan value directly to socket receive methods instead.")] + [Obsolete("Pass a TimeSpan value directly to socket receive methods instead. This will be removed in NetMQ 4.0.")] public TimeSpan ReceiveTimeout { get { return m_socket.GetSocketOptionTimeSpan(ZmqSocketOption.ReceiveTimeout); } @@ -249,7 +249,7 @@ public TimeSpan ReceiveTimeout /// A value of -1 means to block until the message is sent. /// TODO: May need to update this explanation. /// - [Obsolete("Pass a TimeSpan value directly to socket send methods instead.")] + [Obsolete("Pass a TimeSpan value directly to socket send methods instead. This will be removed in NetMQ 4.0.")] public TimeSpan SendTimeout { get { return m_socket.GetSocketOptionTimeSpan(ZmqSocketOption.SendTimeout); } @@ -270,7 +270,7 @@ public bool IPv4Only /// Get the last endpoint bound for TCP and IPC transports. /// The returned value will be a string in the form of a ZMQ DSN. /// - [Obsolete("Use LastEndpoint instead")] + [Obsolete("Use LastEndpoint instead. This will be removed in NetMQ 4.0.")] [CanBeNull] public string GetLastEndpoint { @@ -319,7 +319,7 @@ public bool TcpKeepalive /// /// Unused /// - [Obsolete("This option is not supported and has no effect")] + [Obsolete("This option is not supported and has no effect. This will be removed in NetMQ 4.0.")] public int TcpKeepaliveCnt { set { /* m_socket.SetSocketOption(ZmqSocketOption.TcpKeepaliveCnt, value); */ } @@ -354,7 +354,7 @@ public TimeSpan TcpKeepaliveInterval set { m_socket.SetSocketOptionTimeSpan(ZmqSocketOption.TcpKeepaliveIntvl, value); } } - [Obsolete("This feature has not been implemented and will be removed.")] + [Obsolete("This feature has not been implemented and will be removed in NetMQ 4.0.")] public string TcpAcceptFilter { set { } diff --git a/src/NetMQ/Sockets/PublisherSocket.cs b/src/NetMQ/Sockets/PublisherSocket.cs index eaf203c..104a96b 100644 --- a/src/NetMQ/Sockets/PublisherSocket.cs +++ b/src/NetMQ/Sockets/PublisherSocket.cs @@ -31,7 +31,7 @@ internal PublisherSocket(SocketBase socketHandle) /// doesn't support sending, so this override throws . /// Receive is not supported. - [Obsolete("Use Receive(ref Msg) or TryReceive(ref Msg,TimeSpan) instead.")] + [Obsolete("Use Receive(ref Msg) or TryReceive(ref Msg,TimeSpan) instead. This will be removed in NetMQ 4.0.")] public override void Receive(ref Msg msg, SendReceiveOptions options) { throw new NotSupportedException("PublisherSocket doesn't support receiving"); diff --git a/src/NetMQ/Sockets/PullSocket.cs b/src/NetMQ/Sockets/PullSocket.cs index 4f8b910..4700bd3 100644 --- a/src/NetMQ/Sockets/PullSocket.cs +++ b/src/NetMQ/Sockets/PullSocket.cs @@ -35,7 +35,7 @@ internal PullSocket(SocketBase socketHandle) /// the Msg to transmit /// a SendReceiveOptions that may be None, or any of the bits DontWait, SendMore /// Send must not be called on a PullSocket. - [Obsolete("Use Send(ref Msg, bool) or TrySend(ref Msg,TimeSpan, bool) instead.")] + [Obsolete("Use Send(ref Msg, bool) or TrySend(ref Msg,TimeSpan, bool) instead. This will be removed in NetMQ 4.0.")] public override void Send(ref Msg msg, SendReceiveOptions options) { throw new NotSupportedException("Pull socket doesn't support sending"); diff --git a/src/NetMQ/Sockets/PushSocket.cs b/src/NetMQ/Sockets/PushSocket.cs index c57cd1c..6a4a31b 100644 --- a/src/NetMQ/Sockets/PushSocket.cs +++ b/src/NetMQ/Sockets/PushSocket.cs @@ -31,7 +31,7 @@ internal PushSocket(SocketBase socketHandle) /// doesn't support sending, so this override throws . /// Receive is not supported. - [Obsolete("Use Receive(ref Msg) or TryReceive(ref Msg,TimeSpan) instead.")] + [Obsolete("Use Receive(ref Msg) or TryReceive(ref Msg,TimeSpan) instead. This will be removed in NetMQ 4.0.")] public override void Receive(ref Msg msg, SendReceiveOptions options) { throw new NotSupportedException("PushSocket doesn't support receiving"); diff --git a/src/NetMQ/Sockets/SubscriberSocket.cs b/src/NetMQ/Sockets/SubscriberSocket.cs index 468752a..165b0bf 100644 --- a/src/NetMQ/Sockets/SubscriberSocket.cs +++ b/src/NetMQ/Sockets/SubscriberSocket.cs @@ -36,7 +36,7 @@ internal SubscriberSocket(SocketBase socketHandle) /// the Msg to transmit /// a SendReceiveOptions that may be None, or any of the bits DontWait, SendMore /// Send must not be called on a SubscriberSocket. - [Obsolete("Use Send(ref Msg, bool) or TrySend(ref Msg,TimeSpan, bool) instead.")] + [Obsolete("Use Send(ref Msg, bool) or TrySend(ref Msg,TimeSpan, bool) instead. This will be removed in NetMQ 4.0.")] public override void Send(ref Msg msg, SendReceiveOptions options) { throw new NotSupportedException("Subscriber socket doesn't support sending"); diff --git a/src/NetMQ/ZmqNamespacePlaceholder.cs b/src/NetMQ/ZmqNamespacePlaceholder.cs index a3b1b4a..951d84d 100644 --- a/src/NetMQ/ZmqNamespacePlaceholder.cs +++ b/src/NetMQ/ZmqNamespacePlaceholder.cs @@ -9,6 +9,6 @@ namespace NetMQ.zmq /// All public types have been moved out of the namespace. This class remains /// to prevent compile errors when users still have using NetMQ.zmq; in their code. /// - [Obsolete("Don't use this type!")] + [Obsolete("Don't use this type! It will be removed in NetMQ 4.0.")] public static class ThisNamespaceIsNotUsed { } } \ No newline at end of file