package com.keao.edu.common.entity;

import com.keao.edu.common.enums.MessageSendMode;
import com.keao.edu.common.enums.SendStatusEnum;
import io.swagger.annotations.ApiModelProperty;
import org.apache.commons.lang3.builder.ToStringBuilder;

/**
 * 对应数据库表(sys_message):
 */
public class SysMessage {

	/** 主键 */
	private Long id;
	
	/** 标题 */
	@ApiModelProperty(value = "标题",required = false)
	private String title;
	
	/** 消息内容 */
	@ApiModelProperty(value = "消息内容",required = false)
	private String content;
	
	/** 消息类型；1，表示短信；2，表示邮件; 3,app推送消息 */
	@ApiModelProperty(value = "消息类型",required = false)
	private MessageSendMode type;
	
	/** 状态，-1,发送失败;0,待发送;1,发送中;2,发送完成 */
	@ApiModelProperty(value = "状态",required = false)
	private SendStatusEnum status;
	
	/** 接收人(多个人用逗号分隔) */
	@ApiModelProperty(value = "接收人(多个人用逗号分隔)",required = false)
	private String receiver;
	
	/** 发送时间 */
	@ApiModelProperty(value = "发送时间",required = false)
	private java.util.Date sendTime;
	
	/** 错误信息 */
	@ApiModelProperty(value = "错误信息",required = false)
	private String errorMsg;
	
	/** 创建时间 */
	private java.util.Date createOn;
	
	/** 修改时间 */
	private java.util.Date modifyOn;
	
	/** 用户编号 */
	@ApiModelProperty(value = "用户编号",required = false)
	private Integer userId;
	
	/** 备注 */
	@ApiModelProperty(value = "备注",required = false)
	private String memo;
	
	/** 是否已读 */
	@ApiModelProperty(value = "是否已读",required = false)
	private Integer readStatus;
	
	@ApiModelProperty(value = "消息组",required = false)
	private String group;

	public SysMessage() {
	}

	public SysMessage(String title, String content, MessageSendMode type, String receiver, Integer userId, String memo) {
		this.title = title;
		this.content = content;
		this.type = type;
		this.receiver = receiver;
		this.userId = userId;
		this.memo = memo;
	}

	public void setId(Long id){
		this.id = id;
	}
	
	public Long getId(){
		return this.id;
	}
			
	public void setTitle(String title){
		this.title = title;
	}
	
	public String getTitle(){
		return this.title;
	}
			
	public void setContent(String content){
		this.content = content;
	}
	
	public String getContent(){
		return this.content;
	}
			
	public void setReceiver(String receiver){
		this.receiver = receiver;
	}
	
	public String getReceiver(){
		return this.receiver;
	}
			
	public void setSendTime(java.util.Date sendTime){
		this.sendTime = sendTime;
	}
	
	public java.util.Date getSendTime(){
		return this.sendTime;
	}
			
	public void setErrorMsg(String errorMsg){
		this.errorMsg = errorMsg;
	}
	
	public String getErrorMsg(){
		return this.errorMsg;
	}
			
	public void setCreateOn(java.util.Date createOn){
		this.createOn = createOn;
	}
	
	public java.util.Date getCreateOn(){
		return this.createOn;
	}
			
	public void setModifyOn(java.util.Date modifyOn){
		this.modifyOn = modifyOn;
	}
	
	public java.util.Date getModifyOn(){
		return this.modifyOn;
	}
			
	public void setUserId(Integer userId){
		this.userId = userId;
	}
	
	public Integer getUserId(){
		return this.userId;
	}
			
	public void setMemo(String memo){
		this.memo = memo;
	}
	
	public String getMemo(){
		return this.memo;
	}

	public MessageSendMode getType() {
		return type;
	}

	public void setType(MessageSendMode type) {
		this.type = type;
	}

	public SendStatusEnum getStatus() {
		return status;
	}

	public void setStatus(SendStatusEnum status) {
		this.status = status;
	}

	public Integer getReadStatus() {
		return readStatus;
	}

	public void setReadStatus(Integer readStatus) {
		this.readStatus = readStatus;
	}

	public String getGroup() {
		return group;
	}

	public void setGroup(String group) {
		this.group = group;
	}

	@Override
	public String toString() {
		return ToStringBuilder.reflectionToString(this);
	}

}
