@Service public class UserServiceImpl extends Object implements UserService
| Constructor and Description |
|---|
UserServiceImpl() |
| Modifier and Type | Method and Description |
|---|---|
long |
count(com.querydsl.core.types.Predicate predicate) |
void |
delete(long userId) |
void |
deleteProperties(long userId) |
void |
deleteProperties(User user) |
boolean |
exists(com.querydsl.core.types.Predicate predicate) |
Iterable<User> |
findAll(com.querydsl.core.types.OrderSpecifier<?>... orders) |
Collection<User> |
findAll(com.querydsl.core.types.Predicate predicate) |
Collection<User> |
findAll(com.querydsl.core.types.Predicate predicate,
com.querydsl.core.types.OrderSpecifier<?>... orderSpecifiers) |
org.springframework.data.domain.Page<User> |
findAll(com.querydsl.core.types.Predicate predicate,
org.springframework.data.domain.Pageable pageable) |
Iterable<User> |
findAll(com.querydsl.core.types.Predicate predicate,
org.springframework.data.domain.Sort sort) |
Optional<User> |
findOne(com.querydsl.core.types.Predicate predicate) |
UserProperties |
getProperties(User user) |
Optional<User> |
getUserByEmail(String email) |
Optional<User> |
getUserByEmail(String email,
UserDirectory userDirectory) |
Optional<User> |
getUserById(long id) |
Optional<User> |
getUserByUsername(String username) |
Optional<User> |
getUserByUsername(String username,
UserDirectory userDirectory) |
Collection<User> |
getUsers() |
Collection<User> |
getUsersWithPropertyValue(String propertyName,
Object propertyValue) |
User |
save(User userDto) |
void |
saveProperties(UserProperties userProperties) |
public Collection<User> getUsers()
getUsers in interface UserService@Cacheable(value="securityPrincipalCache",
unless="true && (#result instanceof T(java.util.Optional) && #result.isPresent() ) || (not (#result instanceof T(java.util.Optional)) && #result != null)")
public Optional<User> getUserById(long id)
getUserById in interface UserService@Cacheable(value="userCache",
key="(\'email:\' + #email).toLowerCase()",
unless="true && (#result instanceof T(java.util.Optional) && #result.isPresent() ) || (not (#result instanceof T(java.util.Optional)) && #result != null)")
public Optional<User> getUserByEmail(String email)
getUserByEmail in interface UserServicepublic Optional<User> getUserByEmail(String email, UserDirectory userDirectory)
getUserByEmail in interface UserServicepublic Optional<User> getUserByUsername(String username, UserDirectory userDirectory)
getUserByUsername in interface UserService@Cacheable(value="userCache",
key="(\'username:\' + #username).toLowerCase()",
unless="true && (#result instanceof T(java.util.Optional) && #result.isPresent() ) || (not (#result instanceof T(java.util.Optional)) && #result != null)")
public Optional<User> getUserByUsername(String username)
getUserByUsername in interface UserService@Transactional(value="jpaTransactionManager") public User save(User userDto)
save in interface UserService@Transactional(value="jpaTransactionManager") public void delete(long userId)
delete in interface UserServicepublic void deleteProperties(User user)
deleteProperties in interface UserServicepublic void deleteProperties(long userId)
deleteProperties in interface UserServicepublic UserProperties getProperties(User user)
getProperties in interface UserServicepublic void saveProperties(UserProperties userProperties)
saveProperties in interface UserService@Transactional(value="jpaTransactionManager",
readOnly=true)
public Collection<User> getUsersWithPropertyValue(String propertyName,
Object propertyValue)
getUsersWithPropertyValue in interface UserServicepublic Collection<User> findAll(com.querydsl.core.types.Predicate predicate)
findAll in interface UserServicefindAll in interface org.springframework.data.querydsl.QuerydslPredicateExecutor<User>public Iterable<User> findAll(com.querydsl.core.types.Predicate predicate, org.springframework.data.domain.Sort sort)
findAll in interface UserServicefindAll in interface org.springframework.data.querydsl.QuerydslPredicateExecutor<User>public Optional<User> findOne(com.querydsl.core.types.Predicate predicate)
findOne in interface UserServicefindOne in interface org.springframework.data.querydsl.QuerydslPredicateExecutor<User>public Collection<User> findAll(com.querydsl.core.types.Predicate predicate, com.querydsl.core.types.OrderSpecifier<?>... orderSpecifiers)
findAll in interface UserServicefindAll in interface org.springframework.data.querydsl.QuerydslPredicateExecutor<User>public Iterable<User> findAll(com.querydsl.core.types.OrderSpecifier<?>... orders)
findAll in interface UserServicefindAll in interface org.springframework.data.querydsl.QuerydslPredicateExecutor<User>public org.springframework.data.domain.Page<User> findAll(com.querydsl.core.types.Predicate predicate, org.springframework.data.domain.Pageable pageable)
findAll in interface UserServicefindAll in interface org.springframework.data.querydsl.QuerydslPredicateExecutor<User>public long count(com.querydsl.core.types.Predicate predicate)
count in interface UserServicecount in interface org.springframework.data.querydsl.QuerydslPredicateExecutor<User>public boolean exists(com.querydsl.core.types.Predicate predicate)
exists in interface UserServiceexists in interface org.springframework.data.querydsl.QuerydslPredicateExecutor<User>Copyright © 2020. All rights reserved.