public class DatabaseCredentialStore extends Object implements com.google.api.client.auth.oauth2.CredentialStore
| Modifier and Type | Field and Description |
|---|---|
protected String |
accessTokenProperty |
static String |
copyright |
protected String |
expirationProperty |
protected String |
idProperty |
protected Persistence |
persistence |
protected String |
refreshTokenProperty |
protected Table |
table |
| Constructor and Description |
|---|
DatabaseCredentialStore(Persistence persistence,
String databaseName,
String entityName,
String idProperty,
String accessTokenProperty,
String refreshTokenProperty,
String expirationProperty) |
| Modifier and Type | Method and Description |
|---|---|
protected Object |
create(TableAccessor tableAccessor,
Object idValue) |
protected void |
delete(Session session,
TableAccessor tableAccessor,
Object record) |
void |
delete(String userId,
com.google.api.client.auth.oauth2.Credential credential) |
boolean |
load(String userId,
com.google.api.client.auth.oauth2.Credential credential) |
void |
store(String userId,
com.google.api.client.auth.oauth2.Credential credential) |
public static final String copyright
protected final Persistence persistence
protected final Table table
protected final String idProperty
protected final String accessTokenProperty
protected final String refreshTokenProperty
protected final String expirationProperty
public boolean load(String userId, com.google.api.client.auth.oauth2.Credential credential) throws IOException
load in interface com.google.api.client.auth.oauth2.CredentialStoreIOExceptionpublic void store(String userId, com.google.api.client.auth.oauth2.Credential credential) throws IOException
store in interface com.google.api.client.auth.oauth2.CredentialStoreIOExceptionprotected Object create(TableAccessor tableAccessor, Object idValue)
public void delete(String userId, com.google.api.client.auth.oauth2.Credential credential) throws IOException
delete in interface com.google.api.client.auth.oauth2.CredentialStoreIOExceptionprotected void delete(Session session, TableAccessor tableAccessor, Object record)