Class ConversationUserQueryImpl
- java.lang.Object
-
- com.flowable.engage.engine.impl.conversation.ConversationUserQueryImpl
-
- All Implemented Interfaces:
ConversationUserQuery,Command<List<String>>
public class ConversationUserQueryImpl extends Object implements ConversationUserQuery, Command<List<String>>
The implementation of theConversationUserQueryinterface used to query for users involved in a conversation.- Author:
- Micha Kiener
-
-
Field Summary
Fields Modifier and Type Field Description protected booleanaddAssignedGroupMembersprotected booleanaddAssignedUsersprotected booleanaddCandidateGroupMembersprotected booleanaddParticipantUsersprotected CommandExecutorcommandExecutorprotected StringconversationIdprotected booleanincludeHistoricParticipants
-
Constructor Summary
Constructors Constructor Description ConversationUserQueryImpl(CommandExecutor commandExecutor)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ConversationUserQueryaddAll()This will return all users involved within a conversation, including directly assigned participants, owners and assignees as well as indirectly involved users through group memberships.ConversationUserQueryaddAssignedGroupMembers()Includes all group members of the assigned group of the conversation.ConversationUserQueryaddAssignedUsers()Includes all directly assigned users (e.g.ConversationUserQueryaddCandidateGroupMembers()Includes all group members of all candidate groups of the conversation.ConversationUserQueryaddParticipantUsers()Includes all participants of the conversation.protected voidcheckQuery()ConversationUserQueryconversationId(String conversationId)The id of the conversation to request users for must be provided through its id.longcount()Counts the number of user ids according the query.List<String>execute(CommandContext commandContext)protected CommandExecutorgetCommandExecutor()ConversationUserQueryincludeHistoricParticipants()Includes participants that are not part of the current conversation, but have been part in the past.List<String>list()Returns the list of user ids according the query.protected Collection<String>resolveGroupMembers(String groupId, CommandContext commandContext)
-
-
-
Field Detail
-
commandExecutor
protected final CommandExecutor commandExecutor
-
conversationId
protected String conversationId
-
addAssignedUsers
protected boolean addAssignedUsers
-
addParticipantUsers
protected boolean addParticipantUsers
-
addAssignedGroupMembers
protected boolean addAssignedGroupMembers
-
addCandidateGroupMembers
protected boolean addCandidateGroupMembers
-
includeHistoricParticipants
protected boolean includeHistoricParticipants
-
-
Constructor Detail
-
ConversationUserQueryImpl
public ConversationUserQueryImpl(CommandExecutor commandExecutor)
-
-
Method Detail
-
conversationId
public ConversationUserQuery conversationId(String conversationId)
Description copied from interface:ConversationUserQueryThe id of the conversation to request users for must be provided through its id.- Specified by:
conversationIdin interfaceConversationUserQuery- Parameters:
conversationId- the id of the conversation to request users for- Returns:
- the query builder for chaining
-
addAll
public ConversationUserQuery addAll()
Description copied from interface:ConversationUserQueryThis will return all users involved within a conversation, including directly assigned participants, owners and assignees as well as indirectly involved users through group memberships.- Specified by:
addAllin interfaceConversationUserQuery- Returns:
- the query builder for chaining
-
addAssignedUsers
public ConversationUserQuery addAssignedUsers()
Description copied from interface:ConversationUserQueryIncludes all directly assigned users (e.g. owner and assignee) of the conversation.- Specified by:
addAssignedUsersin interfaceConversationUserQuery- Returns:
- the query builder for chaining
-
addParticipantUsers
public ConversationUserQuery addParticipantUsers()
Description copied from interface:ConversationUserQueryIncludes all participants of the conversation.- Specified by:
addParticipantUsersin interfaceConversationUserQuery- Returns:
- the query builder for chaining
-
addAssignedGroupMembers
public ConversationUserQuery addAssignedGroupMembers()
Description copied from interface:ConversationUserQueryIncludes all group members of the assigned group of the conversation.- Specified by:
addAssignedGroupMembersin interfaceConversationUserQuery- Returns:
- the query builder for chaining
-
addCandidateGroupMembers
public ConversationUserQuery addCandidateGroupMembers()
Description copied from interface:ConversationUserQueryIncludes all group members of all candidate groups of the conversation.- Specified by:
addCandidateGroupMembersin interfaceConversationUserQuery- Returns:
- the query builder for chaining
-
includeHistoricParticipants
public ConversationUserQuery includeHistoricParticipants()
Description copied from interface:ConversationUserQueryIncludes participants that are not part of the current conversation, but have been part in the past.- Specified by:
includeHistoricParticipantsin interfaceConversationUserQuery- Returns:
- the query builder for chaining
-
checkQuery
protected void checkQuery()
-
execute
public List<String> execute(CommandContext commandContext)
-
count
public long count()
Description copied from interface:ConversationUserQueryCounts the number of user ids according the query.- Specified by:
countin interfaceConversationUserQuery- Returns:
- the total user count
-
list
public List<String> list()
Description copied from interface:ConversationUserQueryReturns the list of user ids according the query.- Specified by:
listin interfaceConversationUserQuery- Returns:
- the list of user ids
-
resolveGroupMembers
protected Collection<String> resolveGroupMembers(String groupId, CommandContext commandContext)
-
getCommandExecutor
protected CommandExecutor getCommandExecutor()
-
-