public async Task <T> GetFeeds() { var result = new T(); var widgetControl = new TwitterFeedsManipulator <WidgetGroupItemList>(new GroupObject() { GroupActionUrl = TwitterProfileFiguration.GetSection("GroupActionUrl").Value, GroupHeaderText = TwitterProfileFiguration.GetSection("GroupHeaderText").Value, CacheKey = TwitterProfileFiguration.GetSection("cachKey").Value, CacheTimeInSeconds = TwitterProfileFiguration.GetSection("cacheTimeSecs").Value.ToString(), PageSize = TwitterProfileFiguration.GetSection("PageSize").Value, GroupActionText = TwitterProfileFiguration.GetSection("GroupActionText").Value }); var oauthAthentication = new OauthAuthentication { ConsumerKey = TwitterProfileFiguration.GetSection("OauthConsumerKey").Value, ConsumerSecret = TwitterProfileFiguration.GetSection("OauthConsumerSecret").Value, TokenKey = TwitterProfileFiguration.GetSection("OauthToken").Value, TokenSecret = TwitterProfileFiguration.GetSection("OauthTokenSecret").Value }; result = default(T); string profileTweetUrl = TwitterStatusBaseUrl + string.Format( "include_entities={0}&include_rts={1}&screen_name={2}&count={3}", true, true, TwitterProfileFiguration.GetSection("TwitterProfile").Value, TwitterProfileFiguration.GetSection("PageSize").Value); result = await(widgetControl.GetProfileTwitterFeeds(profileTweetUrl, oauthAthentication) as Task <T>); return(result); }
public T GetFeeds() { var result = new T(); var widgetControl = new TwitterFeedsManipulator <WidgetGroupItemList>(new GroupObject() { GroupActionUrl = TwitterProfileFiguration.Value.GroupActionUrl, GroupHeaderText = TwitterProfileFiguration.Value.GroupHeaderText, CacheKey = TwitterProfileFiguration.Value.cachKey, CacheTimeInSeconds = TwitterProfileFiguration.Value.cacheTimeSecs.ToString(), PageSize = TwitterProfileFiguration.Value.PageSize, GroupActionText = TwitterProfileFiguration.Value.GroupActionText }); var oauthAthentication = new OauthAuthentication { ConsumerKey = TwitterProfileFiguration.Value.OauthConsumerKey, ConsumerSecret = TwitterProfileFiguration.Value.OauthConsumerSecret, TokenKey = TwitterProfileFiguration.Value.OauthToken, TokenSecret = TwitterProfileFiguration.Value.OauthTokenSecret }; result = default(T); string profileTweetUrl = TwitterStatusBaseUrl + string.Format( "include_entities={0}&include_rts={1}&screen_name={2}&count={3}", true, true, TwitterProfileFiguration.Value.TwitterProfile, TwitterProfileFiguration.Value.PageSize); result = (T)widgetControl.GetProfileTwitterFeeds(profileTweetUrl, oauthAthentication); return(result); }