Package com.ibm.cloud.cloudant.security
Class CouchDbSessionAuthenticator.CouchDbSessionToken
java.lang.Object
com.ibm.cloud.sdk.core.security.AbstractToken
com.ibm.cloud.cloudant.security.CouchDbSessionAuthenticator.CouchDbSessionToken
- All Implemented Interfaces:
com.ibm.cloud.sdk.core.security.TokenServerResponse
- Enclosing class:
CouchDbSessionAuthenticator
public static class CouchDbSessionAuthenticator.CouchDbSessionToken
extends com.ibm.cloud.sdk.core.security.AbstractToken
implements com.ibm.cloud.sdk.core.security.TokenServerResponse
Implements
TokenServerResponse
for an Apache CouchDB session cookie.-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionboolean
boolean
Methods inherited from class com.ibm.cloud.sdk.core.security.AbstractToken
getException, setException
-
Field Details
-
expiryTime
public final long expiryTime -
refreshTime
public final long refreshTime
-
-
Constructor Details
-
CouchDbSessionToken
public CouchDbSessionToken(long expiryTime) Constructor for a known expiry time.- Parameters:
expiryTime
- time since epoch that represents the expiry time of this cookie token
-
-
Method Details
-
isTokenValid
public boolean isTokenValid()- Specified by:
isTokenValid
in classcom.ibm.cloud.sdk.core.security.AbstractToken
-
needsRefresh
public boolean needsRefresh()- Specified by:
needsRefresh
in classcom.ibm.cloud.sdk.core.security.AbstractToken
-
getAccessToken
- Specified by:
getAccessToken
in classcom.ibm.cloud.sdk.core.security.AbstractToken
-