public class OAuth2TokenStore extends Object implements com.google.api.client.util.store.DataStore<com.google.api.client.auth.oauth2.StoredCredential>
DataStore
backed by a Nuxeo DirectoryModifier and Type | Field and Description |
---|---|
static String |
DIRECTORY_NAME |
static String |
ENTRY_ID |
Constructor and Description |
---|
OAuth2TokenStore(String serviceName) |
Modifier and Type | Method and Description |
---|---|
com.google.api.client.util.store.DataStore<com.google.api.client.auth.oauth2.StoredCredential> |
clear() |
boolean |
containsKey(String key) |
boolean |
containsValue(com.google.api.client.auth.oauth2.StoredCredential value) |
com.google.api.client.util.store.DataStore<com.google.api.client.auth.oauth2.StoredCredential> |
delete(String key) |
void |
delete(String token,
String clientId) |
com.google.api.client.auth.oauth2.StoredCredential |
get(String key) |
com.google.api.client.util.store.DataStoreFactory |
getDataStoreFactory() |
String |
getId() |
NuxeoOAuth2Token |
getToken(String token)
Retrieve an entry by it's accessToken
|
boolean |
isEmpty() |
Set<String> |
keySet() |
DocumentModelList |
query() |
DocumentModelList |
query(Map<String,Serializable> filter) |
NuxeoOAuth2Token |
refresh(DocumentModel entry,
NuxeoOAuth2Token token) |
NuxeoOAuth2Token |
refresh(String refreshToken,
String clientId) |
com.google.api.client.util.store.DataStore<com.google.api.client.auth.oauth2.StoredCredential> |
set(String key,
com.google.api.client.auth.oauth2.StoredCredential credential) |
int |
size() |
void |
store(String userId,
NuxeoOAuth2Token token) |
Collection<com.google.api.client.auth.oauth2.StoredCredential> |
values() |
public static final String DIRECTORY_NAME
public static final String ENTRY_ID
public OAuth2TokenStore(String serviceName)
public com.google.api.client.util.store.DataStore<com.google.api.client.auth.oauth2.StoredCredential> set(String key, com.google.api.client.auth.oauth2.StoredCredential credential) throws IOException
set
in interface com.google.api.client.util.store.DataStore<com.google.api.client.auth.oauth2.StoredCredential>
IOException
public com.google.api.client.util.store.DataStore<com.google.api.client.auth.oauth2.StoredCredential> delete(String key) throws IOException
delete
in interface com.google.api.client.util.store.DataStore<com.google.api.client.auth.oauth2.StoredCredential>
IOException
public com.google.api.client.auth.oauth2.StoredCredential get(String key) throws IOException
get
in interface com.google.api.client.util.store.DataStore<com.google.api.client.auth.oauth2.StoredCredential>
IOException
public com.google.api.client.util.store.DataStoreFactory getDataStoreFactory()
getDataStoreFactory
in interface com.google.api.client.util.store.DataStore<com.google.api.client.auth.oauth2.StoredCredential>
public final String getId()
getId
in interface com.google.api.client.util.store.DataStore<com.google.api.client.auth.oauth2.StoredCredential>
public boolean containsKey(String key) throws IOException
containsKey
in interface com.google.api.client.util.store.DataStore<com.google.api.client.auth.oauth2.StoredCredential>
IOException
public boolean containsValue(com.google.api.client.auth.oauth2.StoredCredential value) throws IOException
containsValue
in interface com.google.api.client.util.store.DataStore<com.google.api.client.auth.oauth2.StoredCredential>
IOException
public boolean isEmpty() throws IOException
isEmpty
in interface com.google.api.client.util.store.DataStore<com.google.api.client.auth.oauth2.StoredCredential>
IOException
public int size() throws IOException
size
in interface com.google.api.client.util.store.DataStore<com.google.api.client.auth.oauth2.StoredCredential>
IOException
public Set<String> keySet() throws IOException
keySet
in interface com.google.api.client.util.store.DataStore<com.google.api.client.auth.oauth2.StoredCredential>
IOException
public Collection<com.google.api.client.auth.oauth2.StoredCredential> values() throws IOException
values
in interface com.google.api.client.util.store.DataStore<com.google.api.client.auth.oauth2.StoredCredential>
IOException
public com.google.api.client.util.store.DataStore<com.google.api.client.auth.oauth2.StoredCredential> clear() throws IOException
clear
in interface com.google.api.client.util.store.DataStore<com.google.api.client.auth.oauth2.StoredCredential>
IOException
public void store(String userId, NuxeoOAuth2Token token)
public NuxeoOAuth2Token refresh(String refreshToken, String clientId) throws ClientException
ClientException
public NuxeoOAuth2Token refresh(DocumentModel entry, NuxeoOAuth2Token token)
public void delete(String token, String clientId) throws ClientException
ClientException
public NuxeoOAuth2Token getToken(String token) throws ClientException
ClientException
public DocumentModelList query()
public DocumentModelList query(Map<String,Serializable> filter)
Copyright © 2015 Nuxeo SA. All rights reserved.