@Service public class GroupServiceImpl extends Object implements GroupService
| Constructor and Description |
|---|
GroupServiceImpl() |
| Modifier and Type | Method and Description |
|---|---|
long |
count(com.querydsl.core.types.Predicate predicate) |
void |
delete(long groupId) |
void |
deleteProperties(Group group) |
void |
deleteProperties(long groupId) |
boolean |
exists(com.querydsl.core.types.Predicate predicate) |
Iterable<Group> |
findAll(com.querydsl.core.types.OrderSpecifier<?>... orders) |
Collection<Group> |
findAll(com.querydsl.core.types.Predicate predicate) |
Collection<Group> |
findAll(com.querydsl.core.types.Predicate predicate,
com.querydsl.core.types.OrderSpecifier<?>... orderSpecifiers) |
org.springframework.data.domain.Page<Group> |
findAll(com.querydsl.core.types.Predicate predicate,
org.springframework.data.domain.Pageable pageable) |
Iterable<Group> |
findAll(com.querydsl.core.types.Predicate predicate,
org.springframework.data.domain.Sort sort) |
Optional<Group> |
findOne(com.querydsl.core.types.Predicate predicate) |
Optional<Group> |
getGroupById(long id) |
Optional<Group> |
getGroupByName(String name)
Get the group with a given name in the default directory.
|
Optional<Group> |
getGroupByName(String name,
UserDirectory directory)
Get the group with a given name in the specified directory.
|
Collection<Group> |
getGroups() |
Collection<Group> |
getGroupsWithPropertyValue(String propertyName,
Object propertyValue)
Returns all groups having a specific property value.
|
GroupProperties |
getProperties(Group group) |
Group |
save(Group groupDto) |
void |
saveProperties(GroupProperties groupProperties) |
public Collection<Group> getGroups()
getGroups in interface GroupService@Cacheable(value="securityPrincipalCache",
unless="true && (#result instanceof T(java.util.Optional) && #result.isPresent() ) || (not (#result instanceof T(java.util.Optional)) && #result != null)")
public Optional<Group> getGroupById(long id)
getGroupById in interface GroupService@Cacheable(value="groupCache",
unless="true && (#result instanceof T(java.util.Optional) && #result.isPresent() ) || (not (#result instanceof T(java.util.Optional)) && #result != null)")
public Optional<Group> getGroupByName(String name)
GroupServicegetGroupByName in interface GroupServicename - of the groupnull if not found@Cacheable(value="groupCache",
key="#p0 + \':\' + #p1.id",
unless="true && (#result instanceof T(java.util.Optional) && #result.isPresent() ) || (not (#result instanceof T(java.util.Optional)) && #result != null)")
public Optional<Group> getGroupByName(String name,
UserDirectory directory)
GroupServicegetGroupByName in interface GroupServicename - of the groupdirectory - the group should belong tonull if not foundpublic Group save(Group groupDto)
save in interface GroupService@Transactional(value="jpaTransactionManager") public void delete(long groupId)
delete in interface GroupServicepublic GroupProperties getProperties(Group group)
getProperties in interface GroupServicepublic void saveProperties(GroupProperties groupProperties)
saveProperties in interface GroupServicepublic void deleteProperties(Group group)
deleteProperties in interface GroupServicepublic void deleteProperties(long groupId)
deleteProperties in interface GroupService@Transactional(readOnly=true,
value="jpaTransactionManager")
public Collection<Group> getGroupsWithPropertyValue(String propertyName,
Object propertyValue)
GroupServicegetGroupsWithPropertyValue in interface GroupServicepropertyName - name of the propertypropertyValue - value the property should havepublic Collection<Group> findAll(com.querydsl.core.types.Predicate predicate)
findAll in interface GroupServicefindAll in interface org.springframework.data.querydsl.QuerydslPredicateExecutor<Group>public Iterable<Group> findAll(com.querydsl.core.types.Predicate predicate, org.springframework.data.domain.Sort sort)
findAll in interface org.springframework.data.querydsl.QuerydslPredicateExecutor<Group>public Collection<Group> findAll(com.querydsl.core.types.Predicate predicate, com.querydsl.core.types.OrderSpecifier<?>... orderSpecifiers)
findAll in interface GroupServicefindAll in interface org.springframework.data.querydsl.QuerydslPredicateExecutor<Group>public Iterable<Group> findAll(com.querydsl.core.types.OrderSpecifier<?>... orders)
findAll in interface org.springframework.data.querydsl.QuerydslPredicateExecutor<Group>public org.springframework.data.domain.Page<Group> findAll(com.querydsl.core.types.Predicate predicate, org.springframework.data.domain.Pageable pageable)
findAll in interface GroupServicefindAll in interface org.springframework.data.querydsl.QuerydslPredicateExecutor<Group>public long count(com.querydsl.core.types.Predicate predicate)
count in interface GroupServicecount in interface org.springframework.data.querydsl.QuerydslPredicateExecutor<Group>public boolean exists(com.querydsl.core.types.Predicate predicate)
exists in interface org.springframework.data.querydsl.QuerydslPredicateExecutor<Group>public Optional<Group> findOne(com.querydsl.core.types.Predicate predicate)
findOne in interface GroupServicefindOne in interface org.springframework.data.querydsl.QuerydslPredicateExecutor<Group>Copyright © 2020. All rights reserved.