/// <summary> /// Creates a new factory parameter by splitting the specified service URI into ServerUrl and BasePath /// </summary> public FactoryParameters(Uri serviceUri) { serviceUri.ThrowIfNull("serviceUri"); // Retrieve Scheme and Host ServerUrl = serviceUri.GetComponents(UriComponents.SchemeAndServer, UriFormat.UriEscaped); ServerUrl.ThrowIfNullOrEmpty("ServerUrl"); // Retrieve the remaining right part BasePath = serviceUri.GetComponents(UriComponents.PathAndQuery, UriFormat.UriEscaped); BasePath.ThrowIfNullOrEmpty("BasePath"); }