NetMQ.NetMQBeacon.TryReceiveString C# (CSharp) Method

TryReceiveString() public method

Attempt to receive a message from the specified peer for the specified amount of time.
public TryReceiveString ( System.TimeSpan timeout, string &peerName, string &message ) : bool
timeout System.TimeSpan The maximum amount of time the call should wait for a message before returning.
peerName string the name of the peer that the message comes from is written to this string
message string the string to write the received message into
return bool
        public bool TryReceiveString(TimeSpan timeout, out string peerName, out string message)
        {
            if (!m_actor.TryReceiveFrameString(timeout, out peerName))
            {
                message = null;
                return false;
            }

            return m_actor.TryReceiveFrameString(timeout, out message);
        }