Interface SecuredTokensManagement
-
public interface SecuredTokensManagement
Secured tokens API allows for manipulating generic tokens. User with "System Manager" authorization role can manage all tokens. All other users can manage only their own token- Author:
- P.Piernik
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.util.List<pl.edu.icm.unity.base.token.Token>
getAllTokens(java.lang.String type)
User with "System Manager" authorization role can get all tokens.java.util.List<pl.edu.icm.unity.base.token.Token>
getOwnedTokens(java.lang.String type)
Returns all tokens of the logged entityjava.util.List<pl.edu.icm.unity.base.token.Token>
getOwnedTokens(java.lang.String type, pl.edu.icm.unity.types.basic.EntityParam entity)
User with "System Manager" authorization role can get all tokens of all entities.void
removeToken(java.lang.String type, java.lang.String value)
User with "System Manager" authorization role can remove all tokens.
-
-
-
Method Detail
-
getAllTokens
java.util.List<pl.edu.icm.unity.base.token.Token> getAllTokens(java.lang.String type) throws pl.edu.icm.unity.exceptions.EngineException
User with "System Manager" authorization role can get all tokens. All other users can get only own tokens- Parameters:
type
- . If null all types will be return- Returns:
- all tokens of a given type
- Throws:
pl.edu.icm.unity.exceptions.EngineException
-
getOwnedTokens
java.util.List<pl.edu.icm.unity.base.token.Token> getOwnedTokens(java.lang.String type, pl.edu.icm.unity.types.basic.EntityParam entity) throws pl.edu.icm.unity.exceptions.EngineException
User with "System Manager" authorization role can get all tokens of all entities. All other users can get only own tokens.- Parameters:
type
- . If null all types will be returnentity
-- Returns:
- Throws:
pl.edu.icm.unity.exceptions.EngineException
-
getOwnedTokens
java.util.List<pl.edu.icm.unity.base.token.Token> getOwnedTokens(java.lang.String type) throws pl.edu.icm.unity.exceptions.EngineException
Returns all tokens of the logged entity- Parameters:
type
- . If null all types will be returnentity
-- Returns:
- Throws:
pl.edu.icm.unity.exceptions.EngineException
-
removeToken
void removeToken(java.lang.String type, java.lang.String value) throws pl.edu.icm.unity.exceptions.EngineException
User with "System Manager" authorization role can remove all tokens. All other users can remove only own tokens- Parameters:
type
-value
-- Throws:
AuthorizationException
pl.edu.icm.unity.exceptions.EngineException
-
-