Package de.hybris.platform.jalo.user
Class DefaultTokenService
java.lang.Object
de.hybris.platform.jalo.user.DefaultTokenService
- All Implemented Interfaces:
TokenService
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleancheckIfTokenIsValid(String userId, String tokenToCheck) Method verifies if passed token for particular user is validgetOrCreateTokenForUser(String userId) Method should return the current token assigned to user or create it and return it if the token does not existbooleanrevokeTokenForUser(String userId) Method should invalidate the current token for user
-
Constructor Details
-
DefaultTokenService
-
-
Method Details
-
getOrCreateTokenForUser
Description copied from interface:TokenServiceMethod should return the current token assigned to user or create it and return it if the token does not exist- Specified by:
getOrCreateTokenForUserin interfaceTokenService- Parameters:
userId- uid- Returns:
- token assigned to user
-
revokeTokenForUser
Description copied from interface:TokenServiceMethod should invalidate the current token for user- Specified by:
revokeTokenForUserin interfaceTokenService- Parameters:
userId- uid- Returns:
- true if operation was successful
-
checkIfTokenIsValid
Description copied from interface:TokenServiceMethod verifies if passed token for particular user is valid- Specified by:
checkIfTokenIsValidin interfaceTokenService- Parameters:
userId- uidtokenToCheck- token to be verified- Returns:
- true if the token submitted for verification matches the one currently assigned to the user
-