顺便提一下,我会利用签字人授权通过奥阿瑟在谷歌账户中呼吁保护资源。
然而,用户必须每次通过谷歌和准许进入,这似乎只是一种奇怪的。 是否有必要对消费者进行序列化和重新定性,以便不需要再批准? 我试图在共同的偏好中保持原样、秘密和真实性,并将之置于消费者手中,但我收到了奥阿思·斯特雷克基金。
任何想法?
顺便提一下,我会利用签字人授权通过奥阿瑟在谷歌账户中呼吁保护资源。
然而,用户必须每次通过谷歌和准许进入,这似乎只是一种奇怪的。 是否有必要对消费者进行序列化和重新定性,以便不需要再批准? 我试图在共同的偏好中保持原样、秘密和真实性,并将之置于消费者手中,但我收到了奥阿思·斯特雷克基金。
任何想法?
一俟你获得象征性的治疗,你就可以将其储存在你们的首选中:
provider.retrieveAccessToken(consumer, oauth_verifier);
final Editor edit = prefs.edit();
edit.putString(OAuth.OAUTH_TOKEN, consumer.getToken());
edit.putString(OAuth.OAUTH_TOKEN_SECRET, consumer.getTokenSecret());
edit.commit();
之后,你总是能够重新接纳消费者,如:
private OAuthConsumer getConsumer(SharedPreferences prefs) {
String token = prefs.getString(OAuth.OAUTH_TOKEN, "");
String secret = prefs.getString(OAuth.OAUTH_TOKEN_SECRET, "");
OAuthConsumer consumer = new CommonsHttpOAuthConsumer(Constants.CONSUMER_KEY, Constants.CONSUMER_SECRET);
consumer.setTokenWithSecret(token, secret);
return consumer;
}
一旦你去了消费者,你就可以打电话给消费者,消费者会签署。
DefaultHttpClient httpclient = new DefaultHttpClient();
HttpGet request = new HttpGet(url);
consumer.sign(request);
HttpResponse response = httpclient.execute(request);
根据 签字后:
I m relatively new to Android development. I m developing an app with a ListView. I ve followed the info in #1338475 and have my app recognizing the fling gesture, but after the gesture is complete, ...
I m converting my code from using Handler to AsyncTask. The latter is great at what it does - asynchronous updates and handling of results in the main UI thread. What s unclear to me is how to handle ...
I want to be able to download a file with a particular extension from the net, and have it passed to my application to deal with it, but I haven t been able to figure out the intent filter. The ...
I am quite impressed by the workflow I follow when developing Android applications: Define a layout in an xml file and then write all the code in a code-behind style. Is there an equivalent style for ...
To draw landscapes, backgrounds with patterns etc, we used TiledLayer in J2ME. Is there an android counterpart for that. Does android provide an option to set such tiled patterns in the layout XML?
When following the Android Open Source Project instructions on installing repo for use with Git, after running the repo init command, I run into this error: /c/Users/Andrew Rabon/bin/repo: line ...
I read in the Android documentation that by setting my Activity s launchMode property to singleTop OR by adding the FLAG_ACTIVITY_SINGLE_TOP flag to my Intent, that calling startActivity(intent) would ...
I have pretty good skills in PHP , Mysql and Javascript for a junior developer. If I wanted to try my hand as Android Development do you think I might find it tough ? Also what new languages would I ...