use of com.uwetrottmann.seriesguide.backend.account.Account in project SeriesGuide by UweTrottmann.
the class HexagonTools method buildAccountService.
/**
* Creates and returns a new instance for this hexagon service or null if not signed in.
*/
@Nullable
public synchronized Account buildAccountService() {
GoogleAccountCredential credential = getAccountCredential(true);
if (credential.getSelectedAccount() == null) {
return null;
}
Account.Builder builder = new Account.Builder(HTTP_TRANSPORT, JSON_FACTORY, credential);
return CloudEndpointUtils.updateBuilder(app, builder).build();
}
Aggregations