Org.Mentalis.Security.Ssl.SecureSocket.Poll C# (CSharp) Method

Poll() public method

Determines the status of the VirtualSocket.
This property is not supported for SSL/TLS sockets. It can only be used if the SecureProtocol is set to None. Asynchronous behavior in SSL or TLS mode can be achieved by calling the asynchronous methods. Set microSeconds parameter to a negative integer if you would like to wait indefinitely for a response.
The mode parameter is not one of the SelectMode values -or- the socket is in SSL or TLS mode. An operating system error occurs while accessing the VirtualSocket. The VirtualSocket has been closed.
public Poll ( int microSeconds, SelectMode mode ) : bool
microSeconds int The time to wait for a response, in microseconds.
mode SelectMode One of the values.
return bool
		public override bool Poll(int microSeconds, SelectMode mode) {
			if (SecureProtocol != SecureProtocol.None)
				throw new NotSupportedException("The Poll method is not supported in SSL or TLS mode. Use the asynchronous methods and the Available property instead.");
			return base.Poll(microSeconds, mode);
		}
	}