public static class OAuth2CredentialsWithRefresh.Builder extends OAuth2Credentials.Builder
Methods
build()
public OAuth2CredentialsWithRefresh build()
Type | Description |
OAuth2CredentialsWithRefresh |
setAccessToken(AccessToken token)
public OAuth2CredentialsWithRefresh.Builder setAccessToken(AccessToken token)
Sets the AccessToken to be consumed. It must contain an expiration time otherwise an IllegalArgumentException will be thrown.
Name | Description |
token | AccessToken |
Type | Description |
OAuth2CredentialsWithRefresh.Builder |
setRefreshHandler(OAuth2CredentialsWithRefresh.OAuth2RefreshHandler handler)
public OAuth2CredentialsWithRefresh.Builder setRefreshHandler(OAuth2CredentialsWithRefresh.OAuth2RefreshHandler handler)
Sets the OAuth2RefreshHandler to be used for token refreshes.
Name | Description |
handler | OAuth2CredentialsWithRefresh.OAuth2RefreshHandler |
Type | Description |
OAuth2CredentialsWithRefresh.Builder |