Opc.Ua.ServerBase.GetBestDiscoveryUrl C# (CSharp) Method

GetBestDiscoveryUrl() private method

Returns the best discovery URL for the base address based on the URL used by the client.
private GetBestDiscoveryUrl ( Uri clientUrl, BaseAddress baseAddress ) : string
clientUrl System.Uri
baseAddress BaseAddress
return string
        private string GetBestDiscoveryUrl(Uri clientUrl, BaseAddress baseAddress)
        {
            string url = baseAddress.Url.ToString();

            if (baseAddress.ProfileUri == Profiles.WsHttpXmlOrBinaryTransport || baseAddress.ProfileUri == Profiles.WsHttpXmlTransport)
            {
                url += "/discovery";
            }

            return url;
        }