Interface AuthenticationTokenStorage
-
- All Known Implementing Classes:
AbstractAuthenticationTokenStorage
,PersistentAuthenticationTokenStorage
public interface AuthenticationTokenStorage
- Author:
- Dmitrii Bogdanov
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static class
AuthenticationTokenStorage.AlreadyExists
static class
AuthenticationTokenStorage.CreationException
static class
AuthenticationTokenStorage.DeletionException
static class
AuthenticationTokenStorage.InvalidTokenName
static interface
AuthenticationTokenStorage.TokenDescriptor
static class
AuthenticationTokenStorage.TokenException
static class
AuthenticationTokenStorage.TooManyTokens
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description int
count()
int
countByOwnerId(long userId)
void
delete(long userId, String name)
void
deleteAll()
void
deleteAll(long userId)
List<? extends AuthenticationTokenStorage.TokenDescriptor>
deleteExpiredChunk(Integer limit)
List<? extends AuthenticationTokenStorage.TokenDescriptor>
deletePermissionsAndTokenByProjectId(String projectId)
boolean
exists(ParsedToken token)
AuthenticationToken
find(String identifier)
AuthenticationToken
find(String identifier, String value)
Collection<AuthenticationToken>
findAll(long userId)
boolean
hasReachedMaximumNumberOfTokens(long userId)
void
store(AuthenticationToken token)
void
updateLastAccessInfo(String identifier, Date lastAccessDate, String lastAccessRemoteAddress)
-
-
-
Method Detail
-
findAll
@NotNull Collection<AuthenticationToken> findAll(long userId)
-
find
@Nullable AuthenticationToken find(@NotNull String identifier)
-
find
@Nullable AuthenticationToken find(@NotNull String identifier, @NotNull String value)
-
exists
boolean exists(@NotNull ParsedToken token)
-
count
int count()
-
countByOwnerId
int countByOwnerId(long userId)
-
updateLastAccessInfo
void updateLastAccessInfo(@NotNull String identifier, @NotNull Date lastAccessDate, @Nullable String lastAccessRemoteAddress)
-
deleteAll
void deleteAll()
-
deleteAll
void deleteAll(long userId)
-
deletePermissionsAndTokenByProjectId
@NotNull List<? extends AuthenticationTokenStorage.TokenDescriptor> deletePermissionsAndTokenByProjectId(@NotNull String projectId)
-
deleteExpiredChunk
@NotNull List<? extends AuthenticationTokenStorage.TokenDescriptor> deleteExpiredChunk(@Nullable Integer limit)
-
delete
void delete(long userId, @NotNull String name)
-
store
void store(@NotNull AuthenticationToken token)
-
hasReachedMaximumNumberOfTokens
boolean hasReachedMaximumNumberOfTokens(long userId)
-
-