public class MSAAccountInfo extends java.lang.Object implements IAccountInfo
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
ONE_DRIVE_PERSONAL_SERVICE_ROOT
The service root for the OneDrive personal API.
|
| Constructor and Description |
|---|
MSAAccountInfo(MSAAuthenticator authenticator,
LiveConnectSession liveConnectSession,
ILogger logger)
Creates an MSAAccountInfo object.
|
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
getAccessToken()
Get the access token for requests against the service root.
|
AccountType |
getAccountType()
Get the type of the account.
|
java.lang.String |
getServiceRoot()
Get the OneDrive service root for this account.
|
boolean |
isExpired()
Indicates if the account access token is expired and needs to be refreshed.
|
void |
refresh()
Refreshes the authentication token for this account info.
|
public static final java.lang.String ONE_DRIVE_PERSONAL_SERVICE_ROOT
public MSAAccountInfo(MSAAuthenticator authenticator, LiveConnectSession liveConnectSession, ILogger logger)
authenticator - The authenticator that this account info was created from.liveConnectSession - The session this account is based off of.logger - The logger.public AccountType getAccountType()
getAccountType in interface IAccountInfopublic java.lang.String getAccessToken()
getAccessToken in interface IAccountInfopublic java.lang.String getServiceRoot()
getServiceRoot in interface IAccountInfopublic boolean isExpired()
isExpired in interface IAccountInfopublic void refresh()
refresh in interface IAccountInfo