diff options
Diffstat (limited to 'src/DotNetOAuth/Messaging/MessageReceivingEndpoint.cs')
-rw-r--r-- | src/DotNetOAuth/Messaging/MessageReceivingEndpoint.cs | 54 |
1 files changed, 0 insertions, 54 deletions
diff --git a/src/DotNetOAuth/Messaging/MessageReceivingEndpoint.cs b/src/DotNetOAuth/Messaging/MessageReceivingEndpoint.cs deleted file mode 100644 index 2236dd1..0000000 --- a/src/DotNetOAuth/Messaging/MessageReceivingEndpoint.cs +++ /dev/null @@ -1,54 +0,0 @@ -//-----------------------------------------------------------------------
-// <copyright file="MessageReceivingEndpoint.cs" company="Andrew Arnott">
-// Copyright (c) Andrew Arnott. All rights reserved.
-// </copyright>
-//-----------------------------------------------------------------------
-
-namespace DotNetOAuth.Messaging {
- using System;
- using System.Diagnostics;
-
- /// <summary>
- /// An immutable description of a URL that receives messages.
- /// </summary>
- [DebuggerDisplay("{AllowedMethods} {Location}")]
- public class MessageReceivingEndpoint {
- /// <summary>
- /// Initializes a new instance of the <see cref="MessageReceivingEndpoint"/> class.
- /// </summary>
- /// <param name="locationUri">The URL of this endpoint.</param>
- /// <param name="method">The HTTP method(s) allowed.</param>
- public MessageReceivingEndpoint(string locationUri, HttpDeliveryMethods method)
- : this(new Uri(locationUri), method) { }
-
- /// <summary>
- /// Initializes a new instance of the <see cref="MessageReceivingEndpoint"/> class.
- /// </summary>
- /// <param name="location">The URL of this endpoint.</param>
- /// <param name="method">The HTTP method(s) allowed.</param>
- public MessageReceivingEndpoint(Uri location, HttpDeliveryMethods method) {
- if (location == null) {
- throw new ArgumentNullException("location");
- }
- if (method == HttpDeliveryMethods.None) {
- throw new ArgumentOutOfRangeException("method");
- }
- if ((method & (HttpDeliveryMethods.PostRequest | HttpDeliveryMethods.GetRequest)) == 0) {
- throw new ArgumentOutOfRangeException("method", MessagingStrings.GetOrPostFlagsRequired);
- }
-
- this.Location = location;
- this.AllowedMethods = method;
- }
-
- /// <summary>
- /// Gets the URL of this endpoint.
- /// </summary>
- public Uri Location { get; private set; }
-
- /// <summary>
- /// Gets the HTTP method(s) allowed.
- /// </summary>
- public HttpDeliveryMethods AllowedMethods { get; private set; }
- }
-}
|