当前位置: 首页>>代码示例>>C#>>正文


C# ConsumerBase.PrepareAuthorizedRequestAndSend方法代码示例

本文整理汇总了C#中DotNetOpenAuth.OAuth.ConsumerBase.PrepareAuthorizedRequestAndSend方法的典型用法代码示例。如果您正苦于以下问题:C# ConsumerBase.PrepareAuthorizedRequestAndSend方法的具体用法?C# ConsumerBase.PrepareAuthorizedRequestAndSend怎么用?C# ConsumerBase.PrepareAuthorizedRequestAndSend使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在DotNetOpenAuth.OAuth.ConsumerBase的用法示例。


在下文中一共展示了ConsumerBase.PrepareAuthorizedRequestAndSend方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: VerifyCredentials

 public static XDocument VerifyCredentials(ConsumerBase twitter, string accessToken)
 {
     IncomingWebResponse response = twitter.PrepareAuthorizedRequestAndSend(VerifyCredentialsEndpoint, accessToken);
     return XDocument.Load(XmlReader.Create(response.GetResponseReader()));
 }
开发者ID:Inzaghi2012,项目名称:teamlab.v7.5,代码行数:5,代码来源:TwitterConsumer.cs

示例2: GetContacts

        /// <summary>
        /// Gets the Gmail address book's contents.
        /// </summary>
        /// <param name="consumer">The Google consumer previously constructed using <see cref="CreateWebConsumer"/> or <see cref="CreateDesktopConsumer"/>.</param>
        /// <param name="accessToken">The access token previously retrieved.</param>
        /// <returns>An XML document returned by Google.</returns>
        public static XDocument GetContacts(ConsumerBase consumer, string accessToken)
        {
            if (consumer == null) {
                throw new ArgumentNullException("consumer");
            }

            var response = consumer.PrepareAuthorizedRequestAndSend(GetContactsEndpoint, accessToken);
            string body = response.GetResponseReader().ReadToEnd();
            XDocument result = XDocument.Parse(body);
            return result;
        }
开发者ID:jcp-xx,项目名称:dotnetopenid,代码行数:17,代码来源:GoogleConsumer.cs

示例3: GetUpdates

 public static XDocument GetUpdates(ConsumerBase twitter, string accessToken)
 {
     IncomingWebResponse response = twitter.PrepareAuthorizedRequestAndSend(GetFriendTimelineStatusEndpoint, accessToken);
     return XDocument.Load(XmlReader.Create(response.GetResponseReader()));
 }
开发者ID:Inzaghi2012,项目名称:teamlab.v7.5,代码行数:5,代码来源:TwitterConsumer.cs

示例4: GetAuthToken

 public static XDocument GetAuthToken(ConsumerBase flickr, string accessToken)
 {
     IncomingWebResponse response = flickr.PrepareAuthorizedRequestAndSend(ServiceDescription.AccessTokenEndpoint, accessToken);
     return XDocument.Load(XmlReader.Create(response.GetResponseReader()));
 }
开发者ID:havee,项目名称:GiftR,代码行数:5,代码来源:FlickrConsumer.cs


注:本文中的DotNetOpenAuth.OAuth.ConsumerBase.PrepareAuthorizedRequestAndSend方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。