Class SpaceMemberDAOImpl
java.lang.Object
org.exoplatform.commons.persistence.impl.GenericDAOJPAImpl<SpaceMemberEntity,Long>
org.exoplatform.social.core.jpa.storage.dao.jpa.SpaceMemberDAOImpl
- All Implemented Interfaces:
org.exoplatform.commons.api.persistence.GenericDAO<SpaceMemberEntity,,Long> SpaceMemberDAO
public class SpaceMemberDAOImpl
extends org.exoplatform.commons.persistence.impl.GenericDAOJPAImpl<SpaceMemberEntity,Long>
implements SpaceMemberDAO
-
Field Summary
Fields inherited from class org.exoplatform.commons.persistence.impl.GenericDAOJPAImpl
modelClass -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintcountDisabledSpaceMembers(Long spaceId) Count disabled space membersintcountExternalMembers(Long spaceId) Counts the number of external users in a specific spaceintcountPendingSpaceRequestsToManage(String username) intcountSpaceMembers(Long spaceId, SpaceMemberEntity.Status status) Count space members switch statusvoiddeleteBySpace(SpaceEntity entity) getDisabledSpaceMembers(Long spaceId, int offset, int limit) Get disabled space membersList<jakarta.persistence.Tuple> getPendingSpaceRequestsToManage(String username, int offset, int limit) getSpaceIdByMemberId(String username, int offset, int limit) Retrieves the list ofSpacetechnical identifiersgetSpaceIdentityIdsByUserRole(String remoteId, SpaceMemberEntity.Status status, int offset, int limit) Get space identity ids switch user statusgetSpaceIdsByUserRole(String username, SpaceMemberEntity.Status status, int offset, int limit) Retrieves the list ofSpacetechnical identifiers switch statusgetSpaceMembers(Long spaceId, SpaceMemberEntity.Status status, int offset, int limit) Get space members switch statusgetSpaceMemberShip(String remoteId, Long spaceId, SpaceMemberEntity.Status status) getSpacesIdsByUserName(String remoteId, int offset, int limit) sortSpaceMembers(List<String> userNames, String sortField, String sortDirection, boolean filterDisabled) Sort user identity remote idsMethods inherited from class org.exoplatform.commons.persistence.impl.GenericDAOJPAImpl
count, create, createAll, delete, deleteAll, deleteAll, find, findAll, getEntityManager, getHibernateDialect, isMSSQLDialect, isOrcaleDialect, update, updateAllMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.exoplatform.commons.api.persistence.GenericDAO
count, create, createAll, delete, deleteAll, deleteAll, find, findAll, update, updateAll
-
Constructor Details
-
SpaceMemberDAOImpl
public SpaceMemberDAOImpl()
-
-
Method Details
-
deleteBySpace
- Specified by:
deleteBySpacein interfaceSpaceMemberDAO
-
sortSpaceMembers
public List<String> sortSpaceMembers(List<String> userNames, String sortField, String sortDirection, boolean filterDisabled) Description copied from interface:SpaceMemberDAOSort user identity remote ids- Specified by:
sortSpaceMembersin interfaceSpaceMemberDAO- Parameters:
userNames-sortField-sortDirection-filterDisabled-- Returns:
Listof userNames sorted by sortField
-
getSpaceMembers
public List<String> getSpaceMembers(Long spaceId, SpaceMemberEntity.Status status, int offset, int limit) Description copied from interface:SpaceMemberDAOGet space members switch status- Specified by:
getSpaceMembersin interfaceSpaceMemberDAO- Parameters:
spaceId-status- equals to MEMBER, MANAGER, PENDING, INVITED or IGNOREDoffset-limit-- Returns:
-
countSpaceMembers
Description copied from interface:SpaceMemberDAOCount space members switch status- Specified by:
countSpaceMembersin interfaceSpaceMemberDAO- Parameters:
spaceId-status- equals to MEMBER, MANAGER, PENDING, INVITED or IGNORED- Returns:
-
getSpaceMemberShip
public SpaceMemberEntity getSpaceMemberShip(String remoteId, Long spaceId, SpaceMemberEntity.Status status) throws IllegalArgumentException - Specified by:
getSpaceMemberShipin interfaceSpaceMemberDAO- Throws:
IllegalArgumentException
-
getSpaceIdentityIdsByUserRole
public List<Long> getSpaceIdentityIdsByUserRole(String remoteId, SpaceMemberEntity.Status status, int offset, int limit) Description copied from interface:SpaceMemberDAOGet space identity ids switch user status- Specified by:
getSpaceIdentityIdsByUserRolein interfaceSpaceMemberDAO- Parameters:
remoteId- userIdentityremote Idstatus- equals to MEMBER, MANAGER, PENDING, INVITED or IGNOREDoffset- The starting pointlimit- limit of results to retrieve- Returns:
ListofSpacetechnical identifiers of typeLong
-
getSpacesIdsByUserName
- Specified by:
getSpacesIdsByUserNamein interfaceSpaceMemberDAO
-
getSpaceIdByMemberId
Description copied from interface:SpaceMemberDAORetrieves the list ofSpacetechnical identifiers- Specified by:
getSpaceIdByMemberIdin interfaceSpaceMemberDAO- Parameters:
username- user remote idoffset- The starting pointlimit- The limitation of returned results- Returns:
ListofSpacetechnical identifiers of typeLong
-
getSpaceIdsByUserRole
public List<Long> getSpaceIdsByUserRole(String username, SpaceMemberEntity.Status status, int offset, int limit) Description copied from interface:SpaceMemberDAORetrieves the list ofSpacetechnical identifiers switch status- Specified by:
getSpaceIdsByUserRolein interfaceSpaceMemberDAO- Parameters:
username- user remote idstatus- equals to MEMBER, MANAGER, PENDING, INVITED or IGNOREDoffset- The starting pointlimit- The limitation of returned results- Returns:
ListofSpacetechnical identifiers of typeLong
-
getPendingSpaceRequestsToManage
public List<jakarta.persistence.Tuple> getPendingSpaceRequestsToManage(String username, int offset, int limit) - Specified by:
getPendingSpaceRequestsToManagein interfaceSpaceMemberDAO- Parameters:
username- username used to retrieve user spacesoffset- offset of the querylimit- limit of the query- Returns:
ListTupleof users requested to join spaces that designated user (with userId parameter) manages
-
countPendingSpaceRequestsToManage
- Specified by:
countPendingSpaceRequestsToManagein interfaceSpaceMemberDAO- Parameters:
username- username used to retrieve user spaces- Returns:
- the count of users requested to join spaces that user manages
-
countExternalMembers
Description copied from interface:SpaceMemberDAOCounts the number of external users in a specific space- Specified by:
countExternalMembersin interfaceSpaceMemberDAO- Parameters:
spaceId-- Returns:
- counts the external members in the space
-
getDisabledSpaceMembers
Description copied from interface:SpaceMemberDAOGet disabled space members- Specified by:
getDisabledSpaceMembersin interfaceSpaceMemberDAO- Parameters:
spaceId- the space IDoffset- offset of the pagelimit- number of elements on each page- Returns:
- list of user names
-
countDisabledSpaceMembers
Description copied from interface:SpaceMemberDAOCount disabled space members- Specified by:
countDisabledSpaceMembersin interfaceSpaceMemberDAO- Parameters:
spaceId- the spaceID- Returns:
- the number of disabled space members
-