public class NuxeoOAuthToken extends Object implements OAuthToken
OAuthToken
interface. Provides mapping features to DocumentModel so that Token can be
stored in a SQL DirectoryOAuthToken.Type
Constructor and Description |
---|
NuxeoOAuthToken(DocumentModel entry) |
NuxeoOAuthToken(NuxeoOAuthToken originalToken) |
NuxeoOAuthToken(String consumerKey,
String callBack) |
Modifier and Type | Method and Description |
---|---|
String |
getAppId()
Returns consumer application identifier.
|
String |
getCallbackUrl()
Returns consumer call back url (may be used to override what is provided in the
OAuthConsumerRegistry . |
String |
getClientId() |
String |
getConsumerKey()
Gets the Consumer Key.
|
Calendar |
getCreationDate()
Gets creation date of the Token.
|
String |
getNuxeoLogin()
Returns Nuxeo Login as determined during the authorize phase.
|
String |
getToken()
Returns OAuth token.
|
String |
getTokenSecret()
Returns secret associated to the Token.
|
OAuthToken.Type |
getType()
Gets the type of token: REQUEST / ACCESS.
|
String |
getValue(String keyName)
Generic getter (not used for now).
|
String |
getVerifier()
Gets the verifier code.
|
boolean |
isClientToken() |
boolean |
isExpired()
Checks is token is expired.
|
void |
setNuxeoLogin(String login)
Setter for the Login.
|
void |
setValue(String keyName,
String value)
Generic setter (not used for now).
|
void |
updateEntry(DocumentModel entry) |
public static final String SCHEMA
public NuxeoOAuthToken(NuxeoOAuthToken originalToken)
public NuxeoOAuthToken(DocumentModel entry) throws ClientException
ClientException
public void updateEntry(DocumentModel entry) throws ClientException
ClientException
public String getAppId()
OAuthToken
getAppId
in interface OAuthToken
public String getCallbackUrl()
OAuthToken
OAuthConsumerRegistry
.getCallbackUrl
in interface OAuthToken
public String getNuxeoLogin()
OAuthToken
getNuxeoLogin
in interface OAuthToken
public String getToken()
OAuthToken
getToken
in interface OAuthToken
public String getTokenSecret()
OAuthToken
getTokenSecret
in interface OAuthToken
public String getConsumerKey()
OAuthToken
getConsumerKey
in interface OAuthToken
public OAuthToken.Type getType()
OAuthToken
getType
in interface OAuthToken
public Calendar getCreationDate()
OAuthToken
getCreationDate
in interface OAuthToken
public String getValue(String keyName)
OAuthToken
getValue
in interface OAuthToken
public void setValue(String keyName, String value)
OAuthToken
setValue
in interface OAuthToken
public String getVerifier()
OAuthToken
getVerifier
in interface OAuthToken
public boolean isExpired()
OAuthToken
isExpired
in interface OAuthToken
public void setNuxeoLogin(String login)
OAuthToken
setNuxeoLogin
in interface OAuthToken
public boolean isClientToken()
public String getClientId()
Copyright © 2015 Nuxeo SA. All rights reserved.