Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(881)

Delta Between Two Patch Sets: Src/GoogleApis.Auth.DotNet4/OAuth2/GoogleWebAuthorizationBroker.cs

Issue 94340043: Issue 463: Provide a signout\logout method (Closed) Base URL: https://google-api-dotnet-client.googlecode.com/hg/
Left Patch Set: error in reviewing - uploading again Created 9 years, 10 months ago
Right Patch Set: Gus' comments Created 9 years, 10 months ago
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
Left: Side by side diff | Download
Right: Side by side diff | Download
« no previous file with change/comment | « no previous file | Src/GoogleApis.Auth.WP/OAuth2/AuthorizationCodeBroker.cs » ('j') | no next file with change/comment »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
LEFTRIGHT
1 /* 1 /*
2 Copyright 2013 Google Inc 2 Copyright 2013 Google Inc
3 3
4 Licensed under the Apache License, Version 2.0 (the "License"); 4 Licensed under the Apache License, Version 2.0 (the "License");
5 you may not use this file except in compliance with the License. 5 you may not use this file except in compliance with the License.
6 You may obtain a copy of the License at 6 You may obtain a copy of the License at
7 7
8 http://www.apache.org/licenses/LICENSE-2.0 8 http://www.apache.org/licenses/LICENSE-2.0
9 9
10 Unless required by applicable law or agreed to in writing, software 10 Unless required by applicable law or agreed to in writing, software
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
76 { 76 {
77 var initializer = new GoogleAuthorizationCodeFlow.Initializer 77 var initializer = new GoogleAuthorizationCodeFlow.Initializer
78 { 78 {
79 ClientSecretsStream = clientSecretsStream, 79 ClientSecretsStream = clientSecretsStream,
80 }; 80 };
81 return await AuthorizeAsyncCore(initializer, scopes, user, taskCance llationToken, dataStore) 81 return await AuthorizeAsyncCore(initializer, scopes, user, taskCance llationToken, dataStore)
82 .ConfigureAwait(false); 82 .ConfigureAwait(false);
83 } 83 }
84 84
85 /// <summary> 85 /// <summary>
86 /// Asynchronously reauthorizes the user. This method should be called i f the user wants to authorize after· 86 /// Asynchronously reauthorizes the user. This method should be called i f the users want to authorize after·
87 /// they revoked the token. 87 /// they revoked the token.
88 /// </summary> 88 /// </summary>
89 /// <param name="userCredential">The current user credential. Its <see c ref="UserCredential.Token"/> will be 89 /// <param name="userCredential">The current user credential. Its <see c ref="UserCredential.Token"/> will be
90 /// updated. </param> 90 /// updated. </param>
91 /// <param name="taskCancellationToken">Cancellation token to cancel an operation.</param> 91 /// <param name="taskCancellationToken">Cancellation token to cancel an operation.</param>
92 public static async Task ReauthorizeAsync(UserCredential userCredential, 92 public static async Task ReauthorizeAsync(UserCredential userCredential,
93 CancellationToken taskCancellationToken) 93 CancellationToken taskCancellationToken)
94 { 94 {
95 // Create an authorization code installed app instance and authorize the user. 95 // Create an authorization code installed app instance and authorize the user.
96 UserCredential newUserCredential = await new AuthorizationCodeInstal ledApp(userCredential.Flow, 96 UserCredential newUserCredential = await new AuthorizationCodeInstal ledApp(userCredential.Flow,
(...skipping 18 matching lines...) Expand all
115 initializer.Scopes = scopes; 115 initializer.Scopes = scopes;
116 initializer.DataStore = dataStore ?? new FileDataStore(Folder); 116 initializer.DataStore = dataStore ?? new FileDataStore(Folder);
117 var flow = new GoogleAuthorizationCodeFlow(initializer); 117 var flow = new GoogleAuthorizationCodeFlow(initializer);
118 118
119 // Create an authorization code installed app instance and authorize the user. 119 // Create an authorization code installed app instance and authorize the user.
120 return await new AuthorizationCodeInstalledApp(flow, new LocalServer CodeReceiver()).AuthorizeAsync 120 return await new AuthorizationCodeInstalledApp(flow, new LocalServer CodeReceiver()).AuthorizeAsync
121 (user, taskCancellationToken).ConfigureAwait(false); 121 (user, taskCancellationToken).ConfigureAwait(false);
122 } 122 }
123 } 123 }
124 } 124 }
LEFTRIGHT

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b