use of com.zype.android.webapi.model.auth.TokenInfo in project zype-android by zype.
the class LoginActivity method handleAccessTokenInfo.
@Subscribe
public void handleAccessTokenInfo(AccessTokenInfoEvent event) {
Logger.d("handleAccessTokenInfo");
showProgress(false);
TokenInfo data = event.getEventData().getModelData();
SettingsProvider.getInstance().saveAccessTokenApplication(data.getApplicationData());
SettingsProvider.getInstance().saveAccessTokenCreatedAt(data.getCreatedAt());
SettingsProvider.getInstance().saveAccessTokenExpiration(data.getExpiresInSeconds());
SettingsProvider.getInstance().saveAccessTokenResourceOwnerId(data.getResourceOwnerId());
SettingsProvider.getInstance().saveAccessTokenScopes(data.getScopes());
ConsumerParamsBuilder builder = new ConsumerParamsBuilder().addAccessToken();
getApi().executeRequest(WebApiManager.Request.CONSUMER_GET, builder.build());
}
use of com.zype.android.webapi.model.auth.TokenInfo in project zype-android by zype.
the class LoginActivity method handleAccessTokenInfo.
@Subscribe
public void handleAccessTokenInfo(AccessTokenInfoEvent event) {
Logger.d("handleAccessTokenInfo");
showProgress(false);
TokenInfo data = event.getEventData().getModelData();
SettingsProvider.getInstance().saveAccessTokenApplication(data.getApplicationData());
SettingsProvider.getInstance().saveAccessTokenCreatedAt(data.getCreatedAt());
SettingsProvider.getInstance().saveAccessTokenExpiration(data.getExpiresInSeconds());
SettingsProvider.getInstance().saveAccessTokenResourceOwnerId(data.getResourceOwnerId());
SettingsProvider.getInstance().saveAccessTokenScopes(data.getScopes());
ConsumerParamsBuilder builder = new ConsumerParamsBuilder().addAccessToken();
getApi().executeRequest(WebApiManager.Request.CONSUMER_GET, builder.build());
}
Aggregations