ASPC.Marvel.CrimeAPI.TokenHelper.AcsMetadataParser.GetDelegationServiceUrl C# (CSharp) Метод

GetDelegationServiceUrl() публичный статический Метод

public static GetDelegationServiceUrl ( string realm ) : string
realm string
Результат string
            public static string GetDelegationServiceUrl(string realm)
            {
                JsonMetadataDocument document = GetMetadataDocument(realm);

                JsonEndpoint delegationEndpoint = document.endpoints.SingleOrDefault(e => e.protocol == DelegationIssuance);

                if (null != delegationEndpoint)
                {
                    return delegationEndpoint.location;
                }
                throw new Exception("Metadata document does not contain Delegation Service endpoint Url");
            }