public void StoreNewRequestToken(UnauthorizedTokenRequest request, ITokenSecretContainingMessage response) {
			RequestScopedTokenMessage scopedRequest = (RequestScopedTokenMessage)request;
			var consumer = Global.DataContext.OAuthConsumers.Single(consumerRow => consumerRow.ConsumerKey == request.ConsumerKey);
			string scope = scopedRequest.Scope;
			OAuthToken newToken = new OAuthToken {
				OAuthConsumer = consumer,
				Token = response.Token,
				TokenSecret = response.TokenSecret,
				IssueDate = DateTime.UtcNow,
				Scope = scope,
			};

			Global.DataContext.OAuthTokens.InsertOnSubmit(newToken);
			Global.DataContext.SubmitChanges();
		}
		private void detach_OAuthTokens(OAuthToken entity)
		{
			this.SendPropertyChanging();
			entity.OAuthConsumer = null;
		}
 partial void DeleteOAuthToken(OAuthToken instance);
 partial void UpdateOAuthToken(OAuthToken instance);
 partial void InsertOAuthToken(OAuthToken instance);
		private void attach_OAuthTokens(OAuthToken entity)
		{
			this.SendPropertyChanging();
			entity.User = this;
		}
Beispiel #7
0
 private void detach_OAuthTokens(OAuthToken entity)
 {
     this.SendPropertyChanging();
     entity.OAuthConsumer = null;
 }
Beispiel #8
0
 partial void DeleteOAuthToken(OAuthToken instance);
Beispiel #9
0
 partial void UpdateOAuthToken(OAuthToken instance);
Beispiel #10
0
 partial void InsertOAuthToken(OAuthToken instance);
Beispiel #11
0
 private void attach_OAuthTokens(OAuthToken entity)
 {
     this.SendPropertyChanging();
     entity.User = this;
 }