package com.fs.qw.domain;

import lombok.Data;

import java.io.Serializable;
import java.util.HashMap;
import java.util.Map;

@Data
public class QwMessageText implements Serializable {
    private Long receiverId; // 接收人用户id或接收群id
    private Boolean room; // 群消息标记
    private String content; // 消息内容

    // 将对象转为Map
    public Map<String, Object> toMap() {
        Map<String, Object> map = new HashMap<>();
        map.put("receiverId", receiverId);
        map.put("room", room);
        map.put("content", content);
        return map;
    }
}
