예제 #1
0
 public static void IsWellFormedRelativeUri(
     string uri,
     [NotNull, InvokerParameterName] string argName)
 {
     if (!Uri.IsWellFormedUriString(uri, UriKind.Relative))
     {
         throw UriCodeExceptions.ArgumentNotWellFormedUri(argName, uri, UriKind.Relative);
     }
 }
예제 #2
0
 public static void IsWellFormedAbsoluteUri(
     string uri,
     [InvokerParameterName] string argName)
 {
     Code.NotNullNorEmpty(uri, argName);
     if (!Uri.IsWellFormedUriString(uri, UriKind.Absolute))
     {
         throw UriCodeExceptions.ArgumentNotWellFormedUri(argName, uri, UriKind.Absolute);
     }
 }