//-----------------------------------------------------------------------
//
// Copyright (c) Andrew Arnott. All rights reserved.
//
//-----------------------------------------------------------------------
namespace DotNetOAuth.Messages {
using System;
using DotNetOAuth.Messaging;
///
/// A message attached to a request for protected resources that provides the necessary
/// credentials to be granted access to those resources.
///
internal class AccessProtectedResourcesMessage : SignedMessageBase, ITokenContainingMessage {
///
/// Initializes a new instance of the class.
///
/// The URI of the Service Provider endpoint to send this message to.
internal AccessProtectedResourcesMessage(ServiceProviderEndpoint serviceProvider)
: base(MessageTransport.Direct, serviceProvider) {
}
///
/// Gets or sets the Access Token.
///
[MessagePart(Name = "oauth_token", IsRequired = true)]
public string AccessToken { get; set; }
///
/// Gets or sets the Token.
///
string ITokenContainingMessage.Token {
get { return this.AccessToken; }
set { this.AccessToken = value; }
}
}
}