public class GCSTokenCredential extends java.lang.Object implements Credential
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
GCS_TOKEN_CREDENTIAL_TYPE
GCS credential type.
|
static java.lang.String |
GCS_TOKEN_NAME
GCS credential property, token name.
|
CREDENTIAL_TYPE, EXPIRE_TIME_IN_MS
Constructor and Description |
---|
GCSTokenCredential(java.lang.String token,
long expireMs) |
Modifier and Type | Method and Description |
---|---|
java.util.Map<java.lang.String,java.lang.String> |
credentialInfo()
Returns credential information.
|
java.lang.String |
credentialType()
Returns the type of the credential.
|
long |
expireTimeInMs()
Returns the expiration time of the credential in milliseconds since the epoch, 0 means not
expire.
|
java.lang.String |
token()
Get GCS token.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
toProperties
public static final java.lang.String GCS_TOKEN_CREDENTIAL_TYPE
public static final java.lang.String GCS_TOKEN_NAME
public GCSTokenCredential(java.lang.String token, long expireMs)
token
- The GCS token.expireMs
- The GCS token expire time at ms.public java.lang.String credentialType()
Credential
credentialType
in interface Credential
public long expireTimeInMs()
Credential
expireTimeInMs
in interface Credential
public java.util.Map<java.lang.String,java.lang.String> credentialInfo()
Credential
credentialInfo
in interface Credential
public java.lang.String token()