public void Terminate()
{
_disposed = true;
if (_publisherSocket != null)
{
_publisherSocket.Dispose();
_publisherSocket = null;
}
if (_mqContext != null)
{
_mqContext.Terminate();
_mqContext = null;
}
if (_workerReceiverThread != null)
{
_workerReceiverThread.Abort();
_workerReceiverThread = null;
}
if (_workerSenderThread != null)
{
_workerSenderThread.Abort();
_workerSenderThread = null;
}
}