Package com.vaadin.collaborationengine
Class CollaborationMessage
- java.lang.Object
-
- com.vaadin.collaborationengine.CollaborationMessage
-
- All Implemented Interfaces:
Serializable
public class CollaborationMessage extends Object implements Serializable
Message of aCollaborationMessageList.- Since:
- 3.1
- Author:
- Vaadin Ltd
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description CollaborationMessage()Creates a new message.CollaborationMessage(UserInfo user, String text, Instant time)Creates a new message with the specifieduseras the message author info,textas the message content andtimeas the message timestamp.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object o)StringgetText()Gets the message content.InstantgetTime()Gets the message timestamp.UserInfogetUser()Gets the message author user-info.inthashCode()voidsetText(String text)Sets the message content.voidsetTime(Instant time)Sets the message timestamp.voidsetUser(UserInfo user)Sets the message author user-info.
-
-
-
Constructor Detail
-
CollaborationMessage
public CollaborationMessage()
Creates a new message.
-
CollaborationMessage
public CollaborationMessage(UserInfo user, String text, Instant time)
Creates a new message with the specifieduseras the message author info,textas the message content andtimeas the message timestamp.- Parameters:
user- the user-info of the message authortext- the content of the messagetime- the timestamp of the message
-
-
Method Detail
-
getUser
public UserInfo getUser()
Gets the message author user-info.- Returns:
- the user-info
-
setUser
public void setUser(UserInfo user)
Sets the message author user-info.- Parameters:
user- the user-info
-
getText
public String getText()
Gets the message content.- Returns:
- the message content
-
setText
public void setText(String text)
Sets the message content.- Parameters:
text- the message content
-
getTime
public Instant getTime()
Gets the message timestamp.- Returns:
- the message timestamp
-
setTime
public void setTime(Instant time)
Sets the message timestamp.- Parameters:
time- the message timestamp
-
-