Package jetbrains.buildServer.users.impl
Class UserAttributeStorageImpl
- java.lang.Object
-
- jetbrains.buildServer.users.impl.UserAttributeStorageImpl
-
- All Implemented Interfaces:
UserAttributeStorage
public class UserAttributeStorageImpl extends Object implements UserAttributeStorage
- Author:
- Sergey Pestrikov
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface jetbrains.buildServer.users.UserAttributeStorage
UserAttributeStorage.InvalidAttributeKeyException, UserAttributeStorage.UserAttributeException, UserAttributeStorage.UserAttributePersistingException
-
-
Constructor Summary
Constructors Constructor Description UserAttributeStorageImpl(SQLRunnerEx sqlRunner)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleandelete(long userId, String attributeKey)Delete user attributevoiddeleteAll(long userId)Delete all user attributesMap<String,String>findAll(long userId)Find all user attributesList<Long>findUsersIdsByAttributeValue(String attributeKey, String attributeValue, boolean caseSensitive)voidsave(long userId, String attributeKey, String attributeValue)Insert new user attribute or update existing one
-
-
-
Constructor Detail
-
UserAttributeStorageImpl
public UserAttributeStorageImpl(@NotNull SQLRunnerEx sqlRunner)
-
-
Method Detail
-
findAll
@NotNull public Map<String,String> findAll(long userId)
Description copied from interface:UserAttributeStorageFind all user attributes- Specified by:
findAllin interfaceUserAttributeStorage- Parameters:
userId- user id- Returns:
- a mapping of user attributes keys to their values
-
delete
public boolean delete(long userId, @NotNull String attributeKey)Description copied from interface:UserAttributeStorageDelete user attribute- Specified by:
deletein interfaceUserAttributeStorage- Parameters:
userId- user idattributeKey- attribute key- Returns:
- true if the attribute with specified key was deleted and false otherwise
-
deleteAll
public void deleteAll(long userId)
Description copied from interface:UserAttributeStorageDelete all user attributes- Specified by:
deleteAllin interfaceUserAttributeStorage- Parameters:
userId- user id
-
save
public void save(long userId, @NotNull String attributeKey, @NotNull String attributeValue)Description copied from interface:UserAttributeStorageInsert new user attribute or update existing one- Specified by:
savein interfaceUserAttributeStorage- Parameters:
userId- user idattributeKey- attribute keyattributeValue- attribute value
-
findUsersIdsByAttributeValue
public List<Long> findUsersIdsByAttributeValue(@NotNull String attributeKey, @NotNull String attributeValue, boolean caseSensitive)
- Specified by:
findUsersIdsByAttributeValuein interfaceUserAttributeStorage
-
-