SIPSorcery.SIP.SIPProtocolsType.IsAllowedProtocol C# (CSharp) Method

IsAllowedProtocol() public static method

public static IsAllowedProtocol ( string protocol ) : bool
protocol string
return bool
        public static bool IsAllowedProtocol(string protocol)
        {
            try
            {
                Enum.Parse(typeof(SIPProtocolsEnum), protocol, true);
                return true;
            }
            catch
            {
                return false;
            }
        }