dev.struchkov.godfather.main.domain.content.ChatMail Maven / Gradle / Ivy
package dev.struchkov.godfather.main.domain.content;
import lombok.Getter;
import lombok.Setter;
import java.util.ArrayList;
import java.util.Collection;
import java.util.List;
@Getter
@Setter
public class ChatMail extends Message {
public static final String TYPE = "CHAT_MAIL";
private String chatId;
/**
* Имя отправителя.
*/
private String firstName;
/**
* Фамилия отправителя.
*/
private String lastName;
/**
* Вложения к сообщению.
*/
private List attachments = new ArrayList<>();
/**
* Пересланные сообщения.
*/
private List forwardMail;
public void addAttachment(Attachment attachment) {
this.attachments.add(attachment);
}
public void addAttachments(Collection attachments) {
this.attachments.addAll(attachments);
}
}