package com.qs.mp.framework.domain;

import com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlProperty;
import com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlRootElement;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlRootElement;

/**
 * 微信公众号回调消息
 * @author zhongcp
 * @Date 2021/9/24
 */
@XmlRootElement(name = "xml")
@XmlAccessorType(XmlAccessType.FIELD)
@JacksonXmlRootElement(localName ="xml")
public class WxCallbackMsgBody {
  /**开发者微信号*/
  private String toUserName;
  /** 发送消息用户的openId */
  private String fromUserName;
  /** 消息创建时间 */
  private long createTime;
  /** 消息类型 */
  private String msgType;
  /** 消息ID，根据该字段来判重处理 */
  private long msgId;
  /** 文本消息的消息体 */
  private String content;
  /** 事件类型，MsgType为event时这个才有值 */
  private String event;
  /** 事件KEY，MsgType为event时这个才有值 */
  private String eventKey;

  private String status;
  /** 点击的菜单ID */
  private String menuId;

  @JacksonXmlProperty(localName = "ToUserName")
  public String getToUserName() {
    return toUserName;
  }

  public void setToUserName(String toUserName) {
    this.toUserName = toUserName;
  }

  @JacksonXmlProperty(localName = "FromUserName")
  public String getFromUserName() {
    return fromUserName;
  }

  public void setFromUserName(String fromUserName) {
    this.fromUserName = fromUserName;
  }

  @JacksonXmlProperty(localName = "CreateTime")
  public long getCreateTime() {
    return createTime;
  }

  public void setCreateTime(long createTime) {
    this.createTime = createTime;
  }

  @JacksonXmlProperty(localName = "MsgType")
  public String getMsgType() {
    return msgType;
  }

  public void setMsgType(String msgType) {
    this.msgType = msgType;
  }

  @JacksonXmlProperty(localName = "MsgID")
  public long getMsgId() {
    return msgId;
  }

  public void setMsgId(long msgId) {
    this.msgId = msgId;
  }

  @JacksonXmlProperty(localName = "Content")
  public String getContent() {
    return content;
  }

  public void setContent(String content) {
    this.content = content;
  }

  @JacksonXmlProperty(localName = "Event")
  public String getEvent() {
    return event;
  }

  public void setEvent(String event) {
    this.event = event;
  }

  @JacksonXmlProperty(localName = "EventKey")
  public String getEventKey() {
    return eventKey;
  }

  public void setEventKey(String eventKey) {
    this.eventKey = eventKey;
  }

  @JacksonXmlProperty(localName = "Status")
  public String getStatus() {
    return status;
  }

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

  @JacksonXmlProperty(localName = "MenuId")
  public String getMenuId() {
    return menuId;
  }

  public void setMenuId(String menuId) {
    this.menuId = menuId;
  }
}
