Interface MessageGroupFactory
- All Known Implementing Classes:
SimpleMessageGroupFactory
public interface MessageGroupFactory
The
MessageGroup factory strategy.
This strategy is used from the MessageGroup-aware components, e.g. MessageGroupStore.- Since:
- 4.3
- Author:
- Artem Bilan
-
Method Summary
Modifier and Type Method Description MessageGroupcreate(Object groupId)Create aMessageGroupinstance based on the providedgroupId.MessageGroupcreate(Collection<? extends Message<?>> messages, Object groupId)MessageGroupcreate(Collection<? extends Message<?>> messages, Object groupId, long timestamp, boolean complete)MessageGroupcreate(MessageGroupStore messageGroupStore, Object groupId)Create aMessageGroupinstance based on the providedgroupId.MessageGroupcreate(MessageGroupStore messageGroupStore, Object groupId, long timestamp, boolean complete)Create aMessageGroupinstance based on the providedgroupId.
-
Method Details
-
create
Create aMessageGroupinstance based on the providedgroupId.- Parameters:
groupId- the group id to use.- Returns:
- the
MessageGroupinstance.
-
create
- Parameters:
messages- the messages for the group.groupId- the group id to use.- Returns:
- the
MessageGroupinstance.
-
create
MessageGroup create(Collection<? extends Message<?>> messages, Object groupId, long timestamp, boolean complete)Create aMessageGroupinstance based on the providedgroupIdand with themessagesfor the group. In addition the creatingtimestampandcompleteflag may be used to customize the targetMessageGroupobject.- Parameters:
messages- the messages for the group.groupId- the group id to use.timestamp- the creation time.complete- thebooleanflag to indicate that group is completed.- Returns:
- the
MessageGroupinstance.
-
create
Create aMessageGroupinstance based on the providedgroupId. TheMessageGroupStoremay be consulted for the messages and metadata for theMessageGroup.- Parameters:
messageGroupStore- theMessageGroupStorefor additionalMessageGroupinformation.groupId- the group id to use.- Returns:
- the
MessageGroupinstance.
-
create
MessageGroup create(MessageGroupStore messageGroupStore, Object groupId, long timestamp, boolean complete)Create aMessageGroupinstance based on the providedgroupId. TheMessageGroupStoremay be consulted for the messages and metadata for theMessageGroup. In addition the creatingtimestampandcompleteflag may be used to customize the targetMessageGroupobject.- Parameters:
messageGroupStore- theMessageGroupStorefor additionalMessageGroupinformation.groupId- the group id to use.timestamp- the creation time.complete- thebooleanflag to indicate that group is completed.- Returns:
- the
MessageGroupinstance.
-