The best possible way to retreive data from web view
<p>So I was working on an app where the user is allowed to use his/her gmail account to access user-related data specifically related to latitude API , the problem is to access this data I <strong>must</strong> use the OAuth2.0 protocol <a href="https://developers.google.com/accounts/docs/OAuth2" rel="nofollow">Check here</a>, to do so I need to let the user access the account via web view to enter username and password and give permission , the protocol requires to set the redirect_uri to<a href="https://developers.google.com/accounts/docs/OAuth2InstalledApp#choosingredirecturi" rel="nofollow"> either a new page or http://localhost?code=<code>accesscode</code></a>  , to access this data I need that <code>accesscode</code> so I must retrieve it , the only way I did was to set the redirect_uri to <code>localhost</code> use a <code>WebViewClient</code> and override <code>ShouldOverrideLoad</code> and see if the address starts with <code>localhost</code> it extracts the access code return true and use the code , this seems totally inefficient so I want to know if there's any other possible way ,thanks for your help</p>
