Package dev.galasa.framework.spi.auth
Interface IAuthStore
public interface IAuthStore
-
Method Summary
Modifier and TypeMethodDescriptioncreateClient(String clientName) voidcreateUser(String loginId, String clientName, String roleId) Stores a new user record in the users store's database.voiddeleteToken(String tokenId) Deletes an existing token record from the auth store's tokens database.voiddeleteUser(IUser user) Returns a list of all the users using the system.Returns a list of all the token records stored in the auth store.getTokensByLoginId(String loginId) Returns a list of token records stored in the auth store that match a given login ID.Retrieves a user record in the users store's database.getUserByLoginId(String loginId) Retrieves a user record in the users store's database.voidshutdown()voidstoreToken(String clientId, String description, IInternalUser owner) Stores a new token record in the auth store's tokens database.updateUser(IUser user) Updates a user record in the users store's database.
-
Method Details
-
getTokens
Returns a list of all the token records stored in the auth store.- Returns:
- a list of all token records stored in the auth store.
- Throws:
AuthStoreException- if there is an issue accessing the auth store.
-
getTokensByLoginId
Returns a list of token records stored in the auth store that match a given login ID.- Returns:
- a list of all token records stored in the auth store by login ID.
- Throws:
AuthStoreException- if there is an issue accessing the auth store.
-
storeToken
Stores a new token record in the auth store's tokens database.- Parameters:
clientId- the ID of the Dex client that the token works with.description- the user-provided description of the token.owner- the details of the user that the token belongs to.- Throws:
AuthStoreException- if there is an issue accessing the auth store.
-
deleteToken
Deletes an existing token record from the auth store's tokens database.- Parameters:
tokenId- the ID of the token record to delete.- Throws:
AuthStoreException- if there was an issue accessing the auth store.
-
getAllUsers
Returns a list of all the users using the system.- Returns:
- a list of all users stored in the users store.
- Throws:
AuthStoreException- if there is an issue accessing the users store.
-
createUser
Stores a new user record in the users store's database.- Parameters:
loginId- the loginId of the user trying to access Galasa APIclientName- the name of the frontend client being used.roleId- the id of the role this user has been assigned. A numeric value.- Throws:
AuthStoreException- if there is an issue accessing the users store.
-
getUserByLoginId
Retrieves a user record in the users store's database.- Parameters:
loginId- the loginId of the user trying to access Galasa API- Throws:
AuthStoreException- if there is an issue accessing the users store.
-
getUser
Retrieves a user record in the users store's database.- Parameters:
userNumber- the ID of the user record to retrieve- Throws:
AuthStoreException- if there is an issue accessing the users store.
-
updateUser
Updates a user record in the users store's database.- Parameters:
user- The user that needs to be updated- Throws:
AuthStoreException- if there is an issue accessing the users store.
-
shutdown
- Throws:
AuthStoreException
-
deleteUser
- Throws:
AuthStoreException
-
createClient
-