Package org.tailormap.api.persistence
Class TemporaryToken
java.lang.Object
org.tailormap.api.persistence.TemporaryToken
-
Nested Class Summary
Nested Classes -
Constructor Summary
ConstructorsConstructorDescriptionTemporaryToken
(@NotNull TemporaryToken.TokenType tokenType, @NotNull String username, int expirationMinutes) -
Method Summary
Modifier and TypeMethodDescription@NotNull String
Get the token and expiration time as a base64 encoded string.@NotNull UUID
getToken()
setExpirationTime
(ZonedDateTime expirationTime) setTokenType
(TemporaryToken.TokenType tokenType) setUsername
(String username)
-
Constructor Details
-
TemporaryToken
public TemporaryToken() -
TemporaryToken
public TemporaryToken(@NotNull @NotNull TemporaryToken.TokenType tokenType, @NotNull @NotNull String username, int expirationMinutes)
-
-
Method Details
-
getToken
-
setToken
-
getTokenType
-
setTokenType
-
getUsername
-
setUsername
-
getExpirationTime
-
setExpirationTime
-
getCombinedTokenAndExpirationAsBase64
Get the token and expiration time as a base64 encoded string. The format before encoding is: token#expirationEpochSeconds.- Returns:
- base64 encoded token and expiration time
-