private void SetProperties(string name, Uri endpointUri, SAMLAuthenticationType authenticationType) { if (!string.Equals(endpointUri.Scheme, "https", StringComparison.OrdinalIgnoreCase)) { throw new ArgumentException("EndpointUri is not Https protocol."); } if (string.IsNullOrEmpty(name)) { throw new ArgumentException("Name is null or empty."); } Name = name; EndpointUri = endpointUri; AuthenticationType = authenticationType; }
/// <summary> /// Construct a SAMLEndpoint. /// </summary> /// <param name="name">The name of the endpoint.</param> /// <param name="endpointUri">The URI of the endpoint.</param> /// <param name="authenticationType">The authentication type of the endpoint.</param> public SAMLEndpoint(string name, Uri endpointUri, SAMLAuthenticationType authenticationType) { SetProperties(name, endpointUri, authenticationType); }