![JAR search and dependency download from the Maven repository](/logo.png)
net.intelie.live.plugins.messenger.data.UserMessage Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of plugin-messenger Show documentation
Show all versions of plugin-messenger Show documentation
Intelie Live Messenger Plugin
The newest version!
package net.intelie.live.plugins.messenger.data;
public class UserMessage {
private final String uid;
private final RoomData room;
private final UserData author;
private String message;
private Boolean edited;
private long createdAt;
private long timestamp;
private String timeZone;
public UserMessage(String uid, RoomData room, UserData author, String message) {
this(uid, room, author, message, null);
}
public UserMessage(String uid, RoomData room, UserData author, String message, String timeZone) {
this.uid = uid;
this.room = room;
this.author = author;
this.message = message;
this.timestamp = System.currentTimeMillis();
this.createdAt = timestamp;
this.timeZone = timeZone;
}
public String getUid() {
return uid;
}
public RoomData getRoom() {
return room;
}
public String getMessage() {
return message;
}
public UserData getAuthor() {
return author;
}
public String getTimeZone() {
return timeZone;
}
public void setTimeZone(String timeZone) {
this.timeZone = timeZone;
}
public void updateFrom(UserMessage other, MessageSanitizer sanitizer) {
message = sanitizer.sanitize(other.getMessage());
edited = true;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy