diff options
author | Andrew Arnott <andrewarnott@gmail.com> | 2008-09-01 16:06:01 -0700 |
---|---|---|
committer | Andrew <andrewarnott@gmail.com> | 2008-09-01 16:06:01 -0700 |
commit | 4e83c2d321f57cac5e5605097faf15bf1b46efa5 (patch) | |
tree | 3bb5c8dff9b56f1fd2e621417c0a2efcee94adbb /src/DotNetOAuth/UriUtil.cs | |
parent | d5fb1dbbc8388eac763ef85310097a618ff90437 (diff) | |
download | DotNetOpenAuth-4e83c2d321f57cac5e5605097faf15bf1b46efa5.zip DotNetOpenAuth-4e83c2d321f57cac5e5605097faf15bf1b46efa5.tar.gz DotNetOpenAuth-4e83c2d321f57cac5e5605097faf15bf1b46efa5.tar.bz2 |
Lots of StyleCop changes.
Diffstat (limited to 'src/DotNetOAuth/UriUtil.cs')
-rw-r--r-- | src/DotNetOAuth/UriUtil.cs | 29 |
1 files changed, 23 insertions, 6 deletions
diff --git a/src/DotNetOAuth/UriUtil.cs b/src/DotNetOAuth/UriUtil.cs index 9ce913d..74f9e3e 100644 --- a/src/DotNetOAuth/UriUtil.cs +++ b/src/DotNetOAuth/UriUtil.cs @@ -1,12 +1,29 @@ -using System;
-using System.Collections.Specialized;
-using System.Linq;
-using System.Web;
+//-----------------------------------------------------------------------
+// <copyright file="UriUtil.cs" company="Andrew Arnott">
+// Copyright (c) Andrew Arnott. All rights reserved.
+// </copyright>
+//-----------------------------------------------------------------------
namespace DotNetOAuth {
- class UriUtil {
+ using System;
+ using System.Collections.Specialized;
+ using System.Linq;
+ using System.Web;
+
+ /// <summary>
+ /// Utility methods for working with URIs.
+ /// </summary>
+ internal class UriUtil {
+ /// <summary>
+ /// Tests a URI for the presence of an OAuth payload.
+ /// </summary>
+ /// <param name="uri">The URI to test.</param>
+ /// <returns>True if the URI contains an OAuth message.</returns>
internal static bool QueryStringContainsOAuthParameters(Uri uri) {
- if (uri == null) return false;
+ if (uri == null) {
+ return false;
+ }
+
NameValueCollection nvc = HttpUtility.ParseQueryString(uri.Query);
return nvc.Keys.OfType<string>().Any(key => key.StartsWith(Protocol.V10.ParameterPrefix, StringComparison.Ordinal));
}
|