diff options
| author | LukePulverenti Luke Pulverenti luke pulverenti <LukePulverenti Luke Pulverenti luke.pulverenti@gmail.com> | 2012-07-12 23:50:50 -0400 |
|---|---|---|
| committer | LukePulverenti Luke Pulverenti luke pulverenti <LukePulverenti Luke Pulverenti luke.pulverenti@gmail.com> | 2012-07-12 23:50:50 -0400 |
| commit | 5f5f2838b1931a2cf426b778755a417cc662b46f (patch) | |
| tree | 007597d0ba7bc2d992f909c9876744d80cc31b42 /MediaBrowser.Common/Net/CollectionExtensions.cs | |
| parent | 572103cdfe9fdf15ac881a104537047b3ca928ea (diff) | |
moved the http server to common, added more http handlers
Diffstat (limited to 'MediaBrowser.Common/Net/CollectionExtensions.cs')
| -rw-r--r-- | MediaBrowser.Common/Net/CollectionExtensions.cs | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/MediaBrowser.Common/Net/CollectionExtensions.cs b/MediaBrowser.Common/Net/CollectionExtensions.cs new file mode 100644 index 000000000..98d24dfc0 --- /dev/null +++ b/MediaBrowser.Common/Net/CollectionExtensions.cs @@ -0,0 +1,14 @@ +using System.Collections.Generic;
+using System.Collections.Specialized;
+using System.Linq;
+
+namespace MediaBrowser.Common.Net
+{
+ public static class CollectionExtensions
+ {
+ public static IDictionary<string, IEnumerable<string>> ToDictionary(this NameValueCollection source)
+ {
+ return source.AllKeys.ToDictionary<string, string, IEnumerable<string>>(key => key, source.GetValues);
+ }
+ }
+}
\ No newline at end of file |
