修复注释上的link
This commit is contained in:
parent
9290eb2436
commit
98e7b17852
@ -13,7 +13,7 @@ import com.foxinmy.weixin4j.type.MessageType;
|
||||
* @date 2014年4月6日
|
||||
* @since JDK 1.6
|
||||
* @see <a
|
||||
* href="http://mp.weixin.qq.com/wiki/10/79502792eef98d6e0c6e1739da387346.html#.E5.9B.BE.E7.89.87.E6.B6.88.E6.81.AF">订阅号、服务号的图片消息</a>
|
||||
* href="https://mp.weixin.qq.com/wiki?t=resource/res_main&id=mp1421140453&token=&lang=zh_CN">订阅号、服务号的图片消息</a>
|
||||
* @see <a
|
||||
* href="http://qydev.weixin.qq.com/wiki/index.php?title=%E6%8E%A5%E6%94%B6%E6%99%AE%E9%80%9A%E6%B6%88%E6%81%AF#image.E6.B6.88.E6.81.AF">企业号的图片消息</a>
|
||||
*/
|
||||
|
||||
@ -12,8 +12,12 @@ import com.foxinmy.weixin4j.type.MessageType;
|
||||
* @author jy.hu
|
||||
* @date 2014年4月6日
|
||||
* @since JDK 1.6
|
||||
* @see <a
|
||||
* href="http://mp.weixin.qq.com/wiki/10/79502792eef98d6e0c6e1739da387346.html#.E9.93.BE.E6.8E.A5.E6.B6.88.E6.81.AF">订阅号、服务号的链接消息</a>
|
||||
* @see <a href=
|
||||
* "https://mp.weixin.qq.com/wiki?t=resource/res_main&id=mp1421140453&token=&lang=zh_CN">
|
||||
* 订阅号、服务号的链接消息</a>
|
||||
* @see <a href=
|
||||
* "http://qydev.weixin.qq.com/wiki/index.php?title=%E6%8E%A5%E6%94%B6%E6%99%AE%E9%80%9A%E6%B6%88%E6%81%AF#link.E6.B6.88.E6.81.AF">
|
||||
* 企业号的链接消息</a>
|
||||
*/
|
||||
public class LinkMessage extends WeixinMessage {
|
||||
|
||||
@ -53,7 +57,7 @@ public class LinkMessage extends WeixinMessage {
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "LinkMessage [title=" + title + ", description=" + description
|
||||
+ ", url=" + url + ", " + super.toString() + "]";
|
||||
return "LinkMessage [title=" + title + ", description=" + description + ", url=" + url + ", " + super.toString()
|
||||
+ "]";
|
||||
}
|
||||
}
|
||||
|
||||
@ -13,7 +13,7 @@ import com.foxinmy.weixin4j.type.MessageType;
|
||||
* @date 2014年4月6日
|
||||
* @since JDK 1.6
|
||||
* @see <a
|
||||
* href="http://mp.weixin.qq.com/wiki/10/79502792eef98d6e0c6e1739da387346.html#.E5.9C.B0.E7.90.86.E4.BD.8D.E7.BD.AE.E6.B6.88.E6.81.AF">订阅号、服务号的地理位置消息</a>
|
||||
* href="https://mp.weixin.qq.com/wiki?t=resource/res_main&id=mp1421140453&token=&lang=zh_CN">订阅号、服务号的地理位置消息</a>
|
||||
* @see <a
|
||||
* href="http://qydev.weixin.qq.com/wiki/index.php?title=%E6%8E%A5%E6%94%B6%E6%99%AE%E9%80%9A%E6%B6%88%E6%81%AF#location.E6.B6.88.E6.81.AF">企业号的地理位置消息</a>
|
||||
*/
|
||||
|
||||
@ -1,43 +1,43 @@
|
||||
package com.foxinmy.weixin4j.message;
|
||||
|
||||
import javax.xml.bind.annotation.XmlElement;
|
||||
|
||||
import com.foxinmy.weixin4j.request.WeixinMessage;
|
||||
import com.foxinmy.weixin4j.type.MessageType;
|
||||
|
||||
/**
|
||||
* 文本消息
|
||||
*
|
||||
* @className TextMessage
|
||||
* @author jy.hu
|
||||
* @date 2014年4月6日
|
||||
* @since JDK 1.6
|
||||
* @see <a
|
||||
* href="http://mp.weixin.qq.com/wiki/10/79502792eef98d6e0c6e1739da387346.html#.E6.96.87.E6.9C.AC.E6.B6.88.E6.81.AF">订阅号、服务号的文本消息</a>
|
||||
* @see <a
|
||||
* href="http://qydev.weixin.qq.com/wiki/index.php?title=%E6%8E%A5%E6%94%B6%E6%99%AE%E9%80%9A%E6%B6%88%E6%81%AF#text.E6.B6.88.E6.81.AF">企业号的文本消息</a>
|
||||
*/
|
||||
public class TextMessage extends WeixinMessage {
|
||||
|
||||
private static final long serialVersionUID = -7018053906644190260L;
|
||||
|
||||
public TextMessage() {
|
||||
super(MessageType.text.name());
|
||||
}
|
||||
|
||||
/**
|
||||
* 消息内容
|
||||
*/
|
||||
@XmlElement(name = "Content")
|
||||
private String content;
|
||||
|
||||
public String getContent() {
|
||||
return content;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "TextMessage [content=" + content + ", " + super.toString()
|
||||
+ "]";
|
||||
}
|
||||
package com.foxinmy.weixin4j.message;
|
||||
|
||||
import javax.xml.bind.annotation.XmlElement;
|
||||
|
||||
import com.foxinmy.weixin4j.request.WeixinMessage;
|
||||
import com.foxinmy.weixin4j.type.MessageType;
|
||||
|
||||
/**
|
||||
* 文本消息
|
||||
*
|
||||
* @className TextMessage
|
||||
* @author jy.hu
|
||||
* @date 2014年4月6日
|
||||
* @since JDK 1.6
|
||||
* @see <a
|
||||
* href="https://mp.weixin.qq.com/wiki?t=resource/res_main&id=mp1421140453&token=&lang=zh_CN">订阅号、服务号的文本消息</a>
|
||||
* @see <a
|
||||
* href="http://qydev.weixin.qq.com/wiki/index.php?title=%E6%8E%A5%E6%94%B6%E6%99%AE%E9%80%9A%E6%B6%88%E6%81%AF#text.E6.B6.88.E6.81.AF">企业号的文本消息</a>
|
||||
*/
|
||||
public class TextMessage extends WeixinMessage {
|
||||
|
||||
private static final long serialVersionUID = -7018053906644190260L;
|
||||
|
||||
public TextMessage() {
|
||||
super(MessageType.text.name());
|
||||
}
|
||||
|
||||
/**
|
||||
* 消息内容
|
||||
*/
|
||||
@XmlElement(name = "Content")
|
||||
private String content;
|
||||
|
||||
public String getContent() {
|
||||
return content;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "TextMessage [content=" + content + ", " + super.toString()
|
||||
+ "]";
|
||||
}
|
||||
}
|
||||
@ -13,7 +13,7 @@ import com.foxinmy.weixin4j.type.MessageType;
|
||||
* @date 2014年4月6日
|
||||
* @since JDK 1.6
|
||||
* @see <a
|
||||
* href="http://mp.weixin.qq.com/wiki/10/79502792eef98d6e0c6e1739da387346.html#.E8.A7.86.E9.A2.91.E6.B6.88.E6.81.AF">订阅号、服务号的视频消息</a>
|
||||
* href="https://mp.weixin.qq.com/wiki?t=resource/res_main&id=mp1421140453&token=&lang=zh_CN">订阅号、服务号的视频消息</a>
|
||||
* @see <a
|
||||
* href="http://qydev.weixin.qq.com/wiki/index.php?title=%E6%8E%A5%E6%94%B6%E6%99%AE%E9%80%9A%E6%B6%88%E6%81%AF#video.E6.B6.88.E6.81.AF">企业号的视频消息</a>
|
||||
*/
|
||||
|
||||
@ -16,7 +16,7 @@ import com.foxinmy.weixin4j.type.MessageType;
|
||||
* @date 2014年4月6日
|
||||
* @since JDK 1.6
|
||||
* @see <a
|
||||
* href="http://mp.weixin.qq.com/wiki/10/79502792eef98d6e0c6e1739da387346.html#.E8.AF.AD.E9.9F.B3.E6.B6.88.E6.81.AF">订阅号、服务号的语音消息</a>
|
||||
* href="https://mp.weixin.qq.com/wiki?t=resource/res_main&id=mp1421140453&token=&lang=zh_CN">订阅号、服务号的语音消息</a>
|
||||
* @see <a
|
||||
* href="http://qydev.weixin.qq.com/wiki/index.php?title=%E6%8E%A5%E6%94%B6%E6%99%AE%E9%80%9A%E6%B6%88%E6%81%AF#voice.E6.B6.88.E6.81.AF">企业号的语音消息</a>
|
||||
*/
|
||||
|
||||
@ -13,7 +13,7 @@ import com.foxinmy.weixin4j.type.MessageType;
|
||||
* @date 2014年4月6日
|
||||
* @since JDK 1.6
|
||||
* @see <a
|
||||
* href="http://mp.weixin.qq.com/wiki/9/981d772286d10d153a3dc4286c1ee5b5.html">订阅号、服务号的事件推送</a>
|
||||
* href="https://mp.weixin.qq.com/wiki?t=resource/res_main&id=mp1421140454&token=&lang=zh_CN">订阅号、服务号的事件推送</a>
|
||||
* @see <a
|
||||
* href="http://qydev.weixin.qq.com/wiki/index.php?title=%E6%8E%A5%E6%94%B6%E4%BA%8B%E4%BB%B6">企业号的事件消息</a>
|
||||
*/
|
||||
|
||||
@ -12,7 +12,7 @@ import com.foxinmy.weixin4j.type.EventType;
|
||||
* @date 2014年4月6日
|
||||
* @since JDK 1.6
|
||||
* @see <a
|
||||
* href="http://mp.weixin.qq.com/wiki/2/5baf56ce4947d35003b86a9805634b1e.html#.E4.B8.8A.E6.8A.A5.E5.9C.B0.E7.90.86.E4.BD.8D.E7.BD.AE.E4.BA.8B.E4.BB.B6">订阅号、服务号的上报地理位置事件</a>
|
||||
* href="https://mp.weixin.qq.com/wiki?t=resource/res_main&id=mp1421140454&token=&lang=zh_CN">订阅号、服务号的上报地理位置事件</a>
|
||||
* @see <a
|
||||
* href="http://qydev.weixin.qq.com/wiki/index.php?title=%E6%8E%A5%E6%94%B6%E4%BA%8B%E4%BB%B6#.E4.B8.8A.E6.8A.A5.E5.9C.B0.E7.90.86.E4.BD.8D.E7.BD.AE.E4.BA.8B.E4.BB.B6">企业号的上报地理位置事件</a>
|
||||
*/
|
||||
|
||||
@ -12,7 +12,7 @@ import com.foxinmy.weixin4j.type.EventType;
|
||||
* @date 2014年4月6日
|
||||
* @since JDK 1.6
|
||||
* @see <a
|
||||
* href="http://mp.weixin.qq.com/wiki/9/981d772286d10d153a3dc4286c1ee5b5.html#.E7.82.B9.E5.87.BB.E8.8F.9C.E5.8D.95.E6.8B.89.E5.8F.96.E6.B6.88.E6.81.AF.E6.97.B6.E7.9A.84.E4.BA.8B.E4.BB.B6.E6.8E.A8.E9.80.81">订阅号、服务号的菜单事件</a>
|
||||
* href="https://mp.weixin.qq.com/wiki?t=resource/res_main&id=mp1421140454&token=&lang=zh_CN">订阅号、服务号的菜单事件</a>
|
||||
* @see <a
|
||||
* href="http://qydev.weixin.qq.com/wiki/index.php?title=%E6%8E%A5%E6%94%B6%E4%BA%8B%E4%BB%B6#.E4.B8.8A.E6.8A.A5.E8.8F.9C.E5.8D.95.E4.BA.8B.E4.BB.B6">企业号的菜单事件</a>
|
||||
*/
|
||||
|
||||
@ -1,110 +1,110 @@
|
||||
package com.foxinmy.weixin4j.message.event;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
import javax.xml.bind.annotation.XmlElement;
|
||||
|
||||
import com.foxinmy.weixin4j.type.EventType;
|
||||
|
||||
/**
|
||||
* 弹出地理位置选择器的事件推送
|
||||
*
|
||||
* @className MenuLocationEventMessage
|
||||
* @author jy
|
||||
* @date 2014年9月30日
|
||||
* @since JDK 1.6
|
||||
* @see <a
|
||||
* href="http://mp.weixin.qq.com/wiki/9/981d772286d10d153a3dc4286c1ee5b5.html#location_select.EF.BC.9A.E5.BC.B9.E5.87.BA.E5.9C.B0.E7.90.86.E4.BD.8D.E7.BD.AE.E9.80.89.E6.8B.A9.E5.99.A8.E7.9A.84.E4.BA.8B.E4.BB.B6.E6.8E.A8.E9.80.81">订阅号、服务号的弹出地理位置选择事件推送</a>
|
||||
* @see <a
|
||||
* href="http://qydev.weixin.qq.com/wiki/index.php?title=%E6%8E%A5%E6%94%B6%E4%BA%8B%E4%BB%B6#.E5.BC.B9.E5.87.BA.E5.9C.B0.E7.90.86.E4.BD.8D.E7.BD.AE.E9.80.89.E6.8B.A9.E5.99.A8.E7.9A.84.E4.BA.8B.E4.BB.B6.E6.8E.A8.E9.80.81">企业号的弹出地理位置选择事件推送</a>
|
||||
*/
|
||||
public class MenuLocationEventMessage extends MenuEventMessage {
|
||||
|
||||
private static final long serialVersionUID = 145223888272819563L;
|
||||
|
||||
public MenuLocationEventMessage() {
|
||||
super(EventType.location_select);
|
||||
}
|
||||
|
||||
/**
|
||||
* 发送的位置消息
|
||||
*/
|
||||
@XmlElement(name = "SendLocationInfo")
|
||||
private LocationInfo locationInfo;
|
||||
|
||||
public LocationInfo getLocationInfo() {
|
||||
return locationInfo;
|
||||
}
|
||||
|
||||
/**
|
||||
* 地理位置信息
|
||||
*
|
||||
* @className LocationInfo
|
||||
* @author jy
|
||||
* @date 2015年3月29日
|
||||
* @since JDK 1.6
|
||||
* @see
|
||||
*/
|
||||
public static class LocationInfo implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 4904181780216819965L;
|
||||
|
||||
/**
|
||||
* 地理位置维度
|
||||
*/
|
||||
@XmlElement(name = "Location_X")
|
||||
private double x;
|
||||
/**
|
||||
* 地理位置经度
|
||||
*/
|
||||
@XmlElement(name = "Location_Y")
|
||||
private double y;
|
||||
/**
|
||||
* 地图缩放大小
|
||||
*/
|
||||
@XmlElement(name = "Scale")
|
||||
private double scale;
|
||||
/**
|
||||
* 地理位置信息
|
||||
*/
|
||||
@XmlElement(name = "Label")
|
||||
private String label;
|
||||
/**
|
||||
* 朋友圈POI的名字,可能为空
|
||||
*/
|
||||
@XmlElement(name = "Poiname")
|
||||
private String poiname;
|
||||
|
||||
public double getX() {
|
||||
return x;
|
||||
}
|
||||
|
||||
public double getY() {
|
||||
return y;
|
||||
}
|
||||
|
||||
public double getScale() {
|
||||
return scale;
|
||||
}
|
||||
|
||||
public String getLabel() {
|
||||
return label;
|
||||
}
|
||||
|
||||
public String getPoiname() {
|
||||
return poiname;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "LocationInfo [x=" + x + ", y=" + y + ", scale=" + scale
|
||||
+ ", label=" + label + ", poiname=" + poiname + "]";
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "MenuLocationEventMessage [locationInfo=" + locationInfo + ", "
|
||||
+ super.toString() + "]";
|
||||
}
|
||||
}
|
||||
package com.foxinmy.weixin4j.message.event;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
import javax.xml.bind.annotation.XmlElement;
|
||||
|
||||
import com.foxinmy.weixin4j.type.EventType;
|
||||
|
||||
/**
|
||||
* 弹出地理位置选择器的事件推送
|
||||
*
|
||||
* @className MenuLocationEventMessage
|
||||
* @author jy
|
||||
* @date 2014年9月30日
|
||||
* @since JDK 1.6
|
||||
* @see <a
|
||||
* href="https://mp.weixin.qq.com/wiki?t=resource/res_main&id=mp1421140454&token=&lang=zh_CN">订阅号、服务号的弹出地理位置选择事件推送</a>
|
||||
* @see <a
|
||||
* href="http://qydev.weixin.qq.com/wiki/index.php?title=%E6%8E%A5%E6%94%B6%E4%BA%8B%E4%BB%B6#.E5.BC.B9.E5.87.BA.E5.9C.B0.E7.90.86.E4.BD.8D.E7.BD.AE.E9.80.89.E6.8B.A9.E5.99.A8.E7.9A.84.E4.BA.8B.E4.BB.B6.E6.8E.A8.E9.80.81">企业号的弹出地理位置选择事件推送</a>
|
||||
*/
|
||||
public class MenuLocationEventMessage extends MenuEventMessage {
|
||||
|
||||
private static final long serialVersionUID = 145223888272819563L;
|
||||
|
||||
public MenuLocationEventMessage() {
|
||||
super(EventType.location_select);
|
||||
}
|
||||
|
||||
/**
|
||||
* 发送的位置消息
|
||||
*/
|
||||
@XmlElement(name = "SendLocationInfo")
|
||||
private LocationInfo locationInfo;
|
||||
|
||||
public LocationInfo getLocationInfo() {
|
||||
return locationInfo;
|
||||
}
|
||||
|
||||
/**
|
||||
* 地理位置信息
|
||||
*
|
||||
* @className LocationInfo
|
||||
* @author jy
|
||||
* @date 2015年3月29日
|
||||
* @since JDK 1.6
|
||||
* @see
|
||||
*/
|
||||
public static class LocationInfo implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 4904181780216819965L;
|
||||
|
||||
/**
|
||||
* 地理位置维度
|
||||
*/
|
||||
@XmlElement(name = "Location_X")
|
||||
private double x;
|
||||
/**
|
||||
* 地理位置经度
|
||||
*/
|
||||
@XmlElement(name = "Location_Y")
|
||||
private double y;
|
||||
/**
|
||||
* 地图缩放大小
|
||||
*/
|
||||
@XmlElement(name = "Scale")
|
||||
private double scale;
|
||||
/**
|
||||
* 地理位置信息
|
||||
*/
|
||||
@XmlElement(name = "Label")
|
||||
private String label;
|
||||
/**
|
||||
* 朋友圈POI的名字,可能为空
|
||||
*/
|
||||
@XmlElement(name = "Poiname")
|
||||
private String poiname;
|
||||
|
||||
public double getX() {
|
||||
return x;
|
||||
}
|
||||
|
||||
public double getY() {
|
||||
return y;
|
||||
}
|
||||
|
||||
public double getScale() {
|
||||
return scale;
|
||||
}
|
||||
|
||||
public String getLabel() {
|
||||
return label;
|
||||
}
|
||||
|
||||
public String getPoiname() {
|
||||
return poiname;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "LocationInfo [x=" + x + ", y=" + y + ", scale=" + scale
|
||||
+ ", label=" + label + ", poiname=" + poiname + "]";
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "MenuLocationEventMessage [locationInfo=" + locationInfo + ", "
|
||||
+ super.toString() + "]";
|
||||
}
|
||||
}
|
||||
|
||||
@ -1,108 +1,108 @@
|
||||
package com.foxinmy.weixin4j.message.event;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
import javax.xml.bind.annotation.XmlElement;
|
||||
import javax.xml.bind.annotation.XmlElementWrapper;
|
||||
|
||||
/**
|
||||
* 弹出拍照或者相册发图的事件推送(pic_sysphoto|pic_photo_or_album|pic_weixin)
|
||||
*
|
||||
* @className MenuPhotoEventMessage
|
||||
* @author jy
|
||||
* @date 2014年9月30日
|
||||
* @since JDK 1.6
|
||||
* @see <a
|
||||
* href="http://mp.weixin.qq.com/wiki/9/981d772286d10d153a3dc4286c1ee5b5.html#pic_sysphoto.EF.BC.9A.E5.BC.B9.E5.87.BA.E7.B3.BB.E7.BB.9F.E6.8B.8D.E7.85.A7.E5.8F.91.E5.9B.BE.E7.9A.84.E4.BA.8B.E4.BB.B6.E6.8E.A8.E9.80.81">订阅号、服务号的系统发图的事件推送</a>
|
||||
* @see <a
|
||||
* href="http://qydev.weixin.qq.com/wiki/index.php?title=%E6%8E%A5%E6%94%B6%E4%BA%8B%E4%BB%B6#.E5.BC.B9.E5.87.BA.E7.B3.BB.E7.BB.9F.E6.8B.8D.E7.85.A7.E5.8F.91.E5.9B.BE.E7.9A.84.E4.BA.8B.E4.BB.B6.E6.8E.A8.E9.80.81">企业号的系统发图的事件推送</a>
|
||||
*/
|
||||
public class MenuPhotoEventMessage extends MenuEventMessage {
|
||||
|
||||
private static final long serialVersionUID = 3142350663022709730L;
|
||||
|
||||
/**
|
||||
* 发送的图片信息
|
||||
*/
|
||||
@XmlElement(name = "SendPicsInfo")
|
||||
private PictureInfo pictureInfo;
|
||||
|
||||
public PictureInfo getPictureInfo() {
|
||||
return pictureInfo;
|
||||
}
|
||||
|
||||
/**
|
||||
* 图片信息
|
||||
*
|
||||
* @className PictureInfo
|
||||
* @author jy
|
||||
* @date 2015年3月29日
|
||||
* @since JDK 1.6
|
||||
* @see
|
||||
*/
|
||||
public static class PictureInfo implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = -3361375879168233258L;
|
||||
|
||||
/**
|
||||
* 发送的图片数量
|
||||
*/
|
||||
@XmlElement(name = "Count")
|
||||
private int count;
|
||||
/**
|
||||
* 图片列表
|
||||
*/
|
||||
@XmlElementWrapper(name = "PicList")
|
||||
@XmlElement(name = "item")
|
||||
private List<PictureItem> items;
|
||||
|
||||
public int getCount() {
|
||||
return count;
|
||||
}
|
||||
|
||||
public List<PictureItem> getItems() {
|
||||
return items;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "PictureInfo [count=" + count + ", items=" + items + "]";
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 图片
|
||||
*
|
||||
* @className PictureItem
|
||||
* @author jy
|
||||
* @date 2015年3月29日
|
||||
* @since JDK 1.6
|
||||
* @see
|
||||
*/
|
||||
public static class PictureItem implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = -7636697449096645590L;
|
||||
|
||||
/**
|
||||
* 图片的MD5值,开发者若需要,可用于验证接收到图片
|
||||
*/
|
||||
@XmlElement(name = "PicMd5Sum")
|
||||
private String md5;
|
||||
|
||||
public String getMd5() {
|
||||
return md5;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "PictureItem [md5=" + md5 + "]";
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "MenuPhotoEventMessage [pictureInfo=" + pictureInfo + ", "
|
||||
+ super.toString() + "]";
|
||||
}
|
||||
}
|
||||
package com.foxinmy.weixin4j.message.event;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.List;
|
||||
|
||||
import javax.xml.bind.annotation.XmlElement;
|
||||
import javax.xml.bind.annotation.XmlElementWrapper;
|
||||
|
||||
/**
|
||||
* 弹出拍照或者相册发图的事件推送(pic_sysphoto|pic_photo_or_album|pic_weixin)
|
||||
*
|
||||
* @className MenuPhotoEventMessage
|
||||
* @author jy
|
||||
* @date 2014年9月30日
|
||||
* @since JDK 1.6
|
||||
* @see <a
|
||||
* href="https://mp.weixin.qq.com/wiki?t=resource/res_main&id=mp1421140454&token=&lang=zh_CN">订阅号、服务号的系统发图的事件推送</a>
|
||||
* @see <a
|
||||
* href="http://qydev.weixin.qq.com/wiki/index.php?title=%E6%8E%A5%E6%94%B6%E4%BA%8B%E4%BB%B6#.E5.BC.B9.E5.87.BA.E7.B3.BB.E7.BB.9F.E6.8B.8D.E7.85.A7.E5.8F.91.E5.9B.BE.E7.9A.84.E4.BA.8B.E4.BB.B6.E6.8E.A8.E9.80.81">企业号的系统发图的事件推送</a>
|
||||
*/
|
||||
public class MenuPhotoEventMessage extends MenuEventMessage {
|
||||
|
||||
private static final long serialVersionUID = 3142350663022709730L;
|
||||
|
||||
/**
|
||||
* 发送的图片信息
|
||||
*/
|
||||
@XmlElement(name = "SendPicsInfo")
|
||||
private PictureInfo pictureInfo;
|
||||
|
||||
public PictureInfo getPictureInfo() {
|
||||
return pictureInfo;
|
||||
}
|
||||
|
||||
/**
|
||||
* 图片信息
|
||||
*
|
||||
* @className PictureInfo
|
||||
* @author jy
|
||||
* @date 2015年3月29日
|
||||
* @since JDK 1.6
|
||||
* @see
|
||||
*/
|
||||
public static class PictureInfo implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = -3361375879168233258L;
|
||||
|
||||
/**
|
||||
* 发送的图片数量
|
||||
*/
|
||||
@XmlElement(name = "Count")
|
||||
private int count;
|
||||
/**
|
||||
* 图片列表
|
||||
*/
|
||||
@XmlElementWrapper(name = "PicList")
|
||||
@XmlElement(name = "item")
|
||||
private List<PictureItem> items;
|
||||
|
||||
public int getCount() {
|
||||
return count;
|
||||
}
|
||||
|
||||
public List<PictureItem> getItems() {
|
||||
return items;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "PictureInfo [count=" + count + ", items=" + items + "]";
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 图片
|
||||
*
|
||||
* @className PictureItem
|
||||
* @author jy
|
||||
* @date 2015年3月29日
|
||||
* @since JDK 1.6
|
||||
* @see
|
||||
*/
|
||||
public static class PictureItem implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = -7636697449096645590L;
|
||||
|
||||
/**
|
||||
* 图片的MD5值,开发者若需要,可用于验证接收到图片
|
||||
*/
|
||||
@XmlElement(name = "PicMd5Sum")
|
||||
private String md5;
|
||||
|
||||
public String getMd5() {
|
||||
return md5;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "PictureItem [md5=" + md5 + "]";
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "MenuPhotoEventMessage [pictureInfo=" + pictureInfo + ", "
|
||||
+ super.toString() + "]";
|
||||
}
|
||||
}
|
||||
|
||||
@ -1,75 +1,75 @@
|
||||
package com.foxinmy.weixin4j.message.event;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
import javax.xml.bind.annotation.XmlElement;
|
||||
|
||||
/**
|
||||
* 扫码推事件(scancode_push|scancode_waitmsg)
|
||||
*
|
||||
* @className MenuScanEventMessage
|
||||
* @author jy
|
||||
* @date 2014年9月30日
|
||||
* @since JDK 1.6
|
||||
* @see <a
|
||||
* href="http://mp.weixin.qq.com/wiki/9/981d772286d10d153a3dc4286c1ee5b5.html#scancode_push.EF.BC.9A.E6.89.AB.E7.A0.81.E6.8E.A8.E4.BA.8B.E4.BB.B6.E7.9A.84.E4.BA.8B.E4.BB.B6.E6.8E.A8.E9.80.81">订阅号、服务号的扫码推事件</a>
|
||||
* @see <a
|
||||
* href="http://qydev.weixin.qq.com/wiki/index.php?title=%E6%8E%A5%E6%94%B6%E4%BA%8B%E4%BB%B6#.E6.89.AB.E7.A0.81.E6.8E.A8.E4.BA.8B.E4.BB.B6.E7.9A.84.E4.BA.8B.E4.BB.B6.E6.8E.A8.E9.80.81">企业号的的扫码推事件</a>
|
||||
*/
|
||||
public class MenuScanEventMessage extends MenuEventMessage {
|
||||
|
||||
private static final long serialVersionUID = 3142350663022709730L;
|
||||
|
||||
/**
|
||||
* 扫描信息
|
||||
*/
|
||||
@XmlElement(name = "ScanCodeInfo")
|
||||
private ScanInfo scanInfo;
|
||||
|
||||
public ScanInfo getScanInfo() {
|
||||
return scanInfo;
|
||||
}
|
||||
|
||||
/**
|
||||
* 扫描信息
|
||||
*
|
||||
* @className ScanInfo
|
||||
* @author jy
|
||||
* @date 2015年3月29日
|
||||
* @since JDK 1.6
|
||||
* @see
|
||||
*/
|
||||
public static class ScanInfo implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 2237570238164900421L;
|
||||
/**
|
||||
* 扫描类型,一般是qrcode
|
||||
*/
|
||||
@XmlElement(name = "ScanType")
|
||||
private String type;
|
||||
/**
|
||||
* 扫描结果,即二维码对应的字符串信息
|
||||
*/
|
||||
@XmlElement(name = "ScanResult")
|
||||
private String result;
|
||||
|
||||
public String getType() {
|
||||
return type;
|
||||
}
|
||||
|
||||
public String getResult() {
|
||||
return result;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "ScanInfo [type=" + type + ", result=" + result + "]";
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "MenuScanEventMessage [scanInfo=" + scanInfo + ", "
|
||||
+ super.toString() + "]";
|
||||
}
|
||||
}
|
||||
package com.foxinmy.weixin4j.message.event;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
import javax.xml.bind.annotation.XmlElement;
|
||||
|
||||
/**
|
||||
* 扫码推事件(scancode_push|scancode_waitmsg)
|
||||
*
|
||||
* @className MenuScanEventMessage
|
||||
* @author jy
|
||||
* @date 2014年9月30日
|
||||
* @since JDK 1.6
|
||||
* @see <a
|
||||
* href="https://mp.weixin.qq.com/wiki?t=resource/res_main&id=mp1421140454&token=&lang=zh_CN">订阅号、服务号的扫码推事件</a>
|
||||
* @see <a
|
||||
* href="http://qydev.weixin.qq.com/wiki/index.php?title=%E6%8E%A5%E6%94%B6%E4%BA%8B%E4%BB%B6#.E6.89.AB.E7.A0.81.E6.8E.A8.E4.BA.8B.E4.BB.B6.E7.9A.84.E4.BA.8B.E4.BB.B6.E6.8E.A8.E9.80.81">企业号的的扫码推事件</a>
|
||||
*/
|
||||
public class MenuScanEventMessage extends MenuEventMessage {
|
||||
|
||||
private static final long serialVersionUID = 3142350663022709730L;
|
||||
|
||||
/**
|
||||
* 扫描信息
|
||||
*/
|
||||
@XmlElement(name = "ScanCodeInfo")
|
||||
private ScanInfo scanInfo;
|
||||
|
||||
public ScanInfo getScanInfo() {
|
||||
return scanInfo;
|
||||
}
|
||||
|
||||
/**
|
||||
* 扫描信息
|
||||
*
|
||||
* @className ScanInfo
|
||||
* @author jy
|
||||
* @date 2015年3月29日
|
||||
* @since JDK 1.6
|
||||
* @see
|
||||
*/
|
||||
public static class ScanInfo implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 2237570238164900421L;
|
||||
/**
|
||||
* 扫描类型,一般是qrcode
|
||||
*/
|
||||
@XmlElement(name = "ScanType")
|
||||
private String type;
|
||||
/**
|
||||
* 扫描结果,即二维码对应的字符串信息
|
||||
*/
|
||||
@XmlElement(name = "ScanResult")
|
||||
private String result;
|
||||
|
||||
public String getType() {
|
||||
return type;
|
||||
}
|
||||
|
||||
public String getResult() {
|
||||
return result;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "ScanInfo [type=" + type + ", result=" + result + "]";
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "MenuScanEventMessage [scanInfo=" + scanInfo + ", "
|
||||
+ super.toString() + "]";
|
||||
}
|
||||
}
|
||||
|
||||
@ -1,41 +1,41 @@
|
||||
package com.foxinmy.weixin4j.mp.event;
|
||||
|
||||
import javax.xml.bind.annotation.XmlElement;
|
||||
|
||||
import com.foxinmy.weixin4j.message.event.EventMessage;
|
||||
import com.foxinmy.weixin4j.type.EventType;
|
||||
|
||||
/**
|
||||
* 客服关闭会话事件
|
||||
*
|
||||
* @className KfCloseEventMessage
|
||||
* @author jy
|
||||
* @date 2015年3月22日
|
||||
* @since JDK 1.6
|
||||
* @see <a
|
||||
* href="http://mp.weixin.qq.com/wiki/2/6c20f3e323bdf5986cfcb33cbd3b829a.html#.E4.BC.9A.E8.AF.9D.E7.8A.B6.E6.80.81.E9.80.9A.E7.9F.A5.E4.BA.8B.E4.BB.B6">会话状态通知事件</a>
|
||||
*/
|
||||
public class KfCloseEventMessage extends EventMessage {
|
||||
|
||||
private static final long serialVersionUID = 3644449346935205541L;
|
||||
|
||||
public KfCloseEventMessage() {
|
||||
super(EventType.kf_close_session.name());
|
||||
}
|
||||
|
||||
/**
|
||||
* 客服账号
|
||||
*/
|
||||
@XmlElement(name = "KfAccount")
|
||||
private String kfAccount;
|
||||
|
||||
public String getKfAccount() {
|
||||
return kfAccount;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "KfCloseEventMessage [kfAccount=" + kfAccount + ", ="
|
||||
+ super.toString() + "]";
|
||||
}
|
||||
}
|
||||
package com.foxinmy.weixin4j.mp.event;
|
||||
|
||||
import javax.xml.bind.annotation.XmlElement;
|
||||
|
||||
import com.foxinmy.weixin4j.message.event.EventMessage;
|
||||
import com.foxinmy.weixin4j.type.EventType;
|
||||
|
||||
/**
|
||||
* 客服关闭会话事件
|
||||
*
|
||||
* @className KfCloseEventMessage
|
||||
* @author jy
|
||||
* @date 2015年3月22日
|
||||
* @since JDK 1.6
|
||||
* @see <a
|
||||
* href="https://mp.weixin.qq.com/wiki?t=resource/res_main&id=mp1455864026&token=&lang=zh_CN">会话状态通知事件</a>
|
||||
*/
|
||||
public class KfCloseEventMessage extends EventMessage {
|
||||
|
||||
private static final long serialVersionUID = 3644449346935205541L;
|
||||
|
||||
public KfCloseEventMessage() {
|
||||
super(EventType.kf_close_session.name());
|
||||
}
|
||||
|
||||
/**
|
||||
* 客服账号
|
||||
*/
|
||||
@XmlElement(name = "KfAccount")
|
||||
private String kfAccount;
|
||||
|
||||
public String getKfAccount() {
|
||||
return kfAccount;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "KfCloseEventMessage [kfAccount=" + kfAccount + ", ="
|
||||
+ super.toString() + "]";
|
||||
}
|
||||
}
|
||||
|
||||
@ -1,41 +1,41 @@
|
||||
package com.foxinmy.weixin4j.mp.event;
|
||||
|
||||
import javax.xml.bind.annotation.XmlElement;
|
||||
|
||||
import com.foxinmy.weixin4j.message.event.EventMessage;
|
||||
import com.foxinmy.weixin4j.type.EventType;
|
||||
|
||||
/**
|
||||
* 客服接入会话事件
|
||||
*
|
||||
* @className KfCreateEventMessage
|
||||
* @author jy
|
||||
* @date 2015年3月22日
|
||||
* @since JDK 1.6
|
||||
* @see <a
|
||||
* href="http://mp.weixin.qq.com/wiki/2/6c20f3e323bdf5986cfcb33cbd3b829a.html#.E4.BC.9A.E8.AF.9D.E7.8A.B6.E6.80.81.E9.80.9A.E7.9F.A5.E4.BA.8B.E4.BB.B6">会话状态通知事件</a>
|
||||
*/
|
||||
public class KfCreateEventMessage extends EventMessage {
|
||||
|
||||
private static final long serialVersionUID = -8968189700999202108L;
|
||||
|
||||
public KfCreateEventMessage() {
|
||||
super(EventType.kf_create_session.name());
|
||||
}
|
||||
|
||||
/**
|
||||
* 客服账号
|
||||
*/
|
||||
@XmlElement(name = "KfAccount")
|
||||
private String kfAccount;
|
||||
|
||||
public String getKfAccount() {
|
||||
return kfAccount;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "KfCreateEventMessage [kfAccount=" + kfAccount + ", ="
|
||||
+ super.toString() + "]";
|
||||
}
|
||||
}
|
||||
package com.foxinmy.weixin4j.mp.event;
|
||||
|
||||
import javax.xml.bind.annotation.XmlElement;
|
||||
|
||||
import com.foxinmy.weixin4j.message.event.EventMessage;
|
||||
import com.foxinmy.weixin4j.type.EventType;
|
||||
|
||||
/**
|
||||
* 客服接入会话事件
|
||||
*
|
||||
* @className KfCreateEventMessage
|
||||
* @author jy
|
||||
* @date 2015年3月22日
|
||||
* @since JDK 1.6
|
||||
* @see <a
|
||||
* href="https://mp.weixin.qq.com/wiki?t=resource/res_main&id=mp1455864026&token=&lang=zh_CN">会话状态通知事件</a>
|
||||
*/
|
||||
public class KfCreateEventMessage extends EventMessage {
|
||||
|
||||
private static final long serialVersionUID = -8968189700999202108L;
|
||||
|
||||
public KfCreateEventMessage() {
|
||||
super(EventType.kf_create_session.name());
|
||||
}
|
||||
|
||||
/**
|
||||
* 客服账号
|
||||
*/
|
||||
@XmlElement(name = "KfAccount")
|
||||
private String kfAccount;
|
||||
|
||||
public String getKfAccount() {
|
||||
return kfAccount;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "KfCreateEventMessage [kfAccount=" + kfAccount + ", ="
|
||||
+ super.toString() + "]";
|
||||
}
|
||||
}
|
||||
|
||||
@ -1,50 +1,50 @@
|
||||
package com.foxinmy.weixin4j.mp.event;
|
||||
|
||||
import javax.xml.bind.annotation.XmlElement;
|
||||
|
||||
import com.foxinmy.weixin4j.message.event.EventMessage;
|
||||
import com.foxinmy.weixin4j.type.EventType;
|
||||
|
||||
/**
|
||||
* 客服转接会话事件
|
||||
*
|
||||
* @className KfSwitchEventMessage
|
||||
* @author jy
|
||||
* @date 2015年3月22日
|
||||
* @since JDK 1.6
|
||||
* @see <a
|
||||
* href="http://mp.weixin.qq.com/wiki/2/6c20f3e323bdf5986cfcb33cbd3b829a.html#.E4.BC.9A.E8.AF.9D.E7.8A.B6.E6.80.81.E9.80.9A.E7.9F.A5.E4.BA.8B.E4.BB.B6">会话状态通知事件</a>
|
||||
*/
|
||||
public class KfSwitchEventMessage extends EventMessage {
|
||||
|
||||
private static final long serialVersionUID = 4319501074109623413L;
|
||||
|
||||
public KfSwitchEventMessage() {
|
||||
super(EventType.kf_switch_session.name());
|
||||
}
|
||||
|
||||
/**
|
||||
* 来自的客服账号
|
||||
*/
|
||||
@XmlElement(name = "FromKfAccount")
|
||||
private String fromKfAccount;
|
||||
/**
|
||||
* 转移给客服账号
|
||||
*/
|
||||
@XmlElement(name = "ToKfAccount")
|
||||
private String toKfAccount;
|
||||
|
||||
public String getFromKfAccount() {
|
||||
return fromKfAccount;
|
||||
}
|
||||
|
||||
public String getToKfAccount() {
|
||||
return toKfAccount;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "KfSwitchEventMessage [fromKfAccount=" + fromKfAccount
|
||||
+ ", toKfAccount=" + toKfAccount + "]";
|
||||
}
|
||||
}
|
||||
package com.foxinmy.weixin4j.mp.event;
|
||||
|
||||
import javax.xml.bind.annotation.XmlElement;
|
||||
|
||||
import com.foxinmy.weixin4j.message.event.EventMessage;
|
||||
import com.foxinmy.weixin4j.type.EventType;
|
||||
|
||||
/**
|
||||
* 客服转接会话事件
|
||||
*
|
||||
* @className KfSwitchEventMessage
|
||||
* @author jy
|
||||
* @date 2015年3月22日
|
||||
* @since JDK 1.6
|
||||
* @see <a
|
||||
* href="https://mp.weixin.qq.com/wiki?t=resource/res_main&id=mp1455864026&token=&lang=zh_CN">会话状态通知事件</a>
|
||||
*/
|
||||
public class KfSwitchEventMessage extends EventMessage {
|
||||
|
||||
private static final long serialVersionUID = 4319501074109623413L;
|
||||
|
||||
public KfSwitchEventMessage() {
|
||||
super(EventType.kf_switch_session.name());
|
||||
}
|
||||
|
||||
/**
|
||||
* 来自的客服账号
|
||||
*/
|
||||
@XmlElement(name = "FromKfAccount")
|
||||
private String fromKfAccount;
|
||||
/**
|
||||
* 转移给客服账号
|
||||
*/
|
||||
@XmlElement(name = "ToKfAccount")
|
||||
private String toKfAccount;
|
||||
|
||||
public String getFromKfAccount() {
|
||||
return fromKfAccount;
|
||||
}
|
||||
|
||||
public String getToKfAccount() {
|
||||
return toKfAccount;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "KfSwitchEventMessage [fromKfAccount=" + fromKfAccount
|
||||
+ ", toKfAccount=" + toKfAccount + "]";
|
||||
}
|
||||
}
|
||||
|
||||
@ -1,80 +1,80 @@
|
||||
package com.foxinmy.weixin4j.mp.event;
|
||||
|
||||
import javax.xml.bind.annotation.XmlElement;
|
||||
|
||||
import com.foxinmy.weixin4j.message.event.EventMessage;
|
||||
import com.foxinmy.weixin4j.type.EventType;
|
||||
|
||||
/**
|
||||
* 群发消息事件推送
|
||||
*
|
||||
* @className MassEventMessage
|
||||
* @author jy
|
||||
* @date 2014年4月27日
|
||||
* @since JDK 1.6
|
||||
* @see <a
|
||||
* href="http://mp.weixin.qq.com/wiki/15/5380a4e6f02f2ffdc7981a8ed7a40753.html#.E4.BA.8B.E4.BB.B6.E6.8E.A8.E9.80.81.E7.BE.A4.E5.8F.91.E7.BB.93.E6.9E.9C">群发回调</a>
|
||||
*/
|
||||
public class MassEventMessage extends EventMessage {
|
||||
|
||||
private static final long serialVersionUID = -1660543255873723895L;
|
||||
|
||||
public MassEventMessage() {
|
||||
super(EventType.masssendjobfinish.name());
|
||||
}
|
||||
|
||||
/**
|
||||
* 群发后的状态信息 为“send success”或“send fail”或“err(num)
|
||||
*/
|
||||
@XmlElement(name = "Status")
|
||||
private String status;
|
||||
/**
|
||||
* group_id下粉丝数;或者openid_list中的粉丝数
|
||||
*/
|
||||
@XmlElement(name = "TotalCount")
|
||||
private int totalCount;
|
||||
/**
|
||||
* 过滤(过滤是指特定地区、性别的过滤、用户设置拒收的过滤,用户接收已超4条的过滤)后,准备发送的粉丝数,原则上,FilterCount =
|
||||
* SentCount + ErrorCount
|
||||
*/
|
||||
@XmlElement(name = "FilterCount")
|
||||
private int filterCount;
|
||||
/**
|
||||
* 发送成功的粉丝数
|
||||
*/
|
||||
@XmlElement(name = "SentCount")
|
||||
private int sentCount;
|
||||
/**
|
||||
* 发送失败的粉丝数
|
||||
*/
|
||||
@XmlElement(name = "ErrorCount")
|
||||
private int errorCount;
|
||||
|
||||
public String getStatus() {
|
||||
return status;
|
||||
}
|
||||
|
||||
public int getTotalCount() {
|
||||
return totalCount;
|
||||
}
|
||||
|
||||
public int getFilterCount() {
|
||||
return filterCount;
|
||||
}
|
||||
|
||||
public int getSentCount() {
|
||||
return sentCount;
|
||||
}
|
||||
|
||||
public int getErrorCount() {
|
||||
return errorCount;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "MassEventMessage [status=" + status + ", totalCount="
|
||||
+ totalCount + ", filterCount=" + filterCount + ", sentCount="
|
||||
+ sentCount + ", errorCount=" + errorCount + ", "
|
||||
+ super.toString() + "]";
|
||||
}
|
||||
}
|
||||
package com.foxinmy.weixin4j.mp.event;
|
||||
|
||||
import javax.xml.bind.annotation.XmlElement;
|
||||
|
||||
import com.foxinmy.weixin4j.message.event.EventMessage;
|
||||
import com.foxinmy.weixin4j.type.EventType;
|
||||
|
||||
/**
|
||||
* 群发消息事件推送
|
||||
*
|
||||
* @className MassEventMessage
|
||||
* @author jy
|
||||
* @date 2014年4月27日
|
||||
* @since JDK 1.6
|
||||
* @see <a
|
||||
* href="https://mp.weixin.qq.com/wiki?t=resource/res_main&id=mp1421140549&token=&lang=zh_CN">群发回调</a>
|
||||
*/
|
||||
public class MassEventMessage extends EventMessage {
|
||||
|
||||
private static final long serialVersionUID = -1660543255873723895L;
|
||||
|
||||
public MassEventMessage() {
|
||||
super(EventType.masssendjobfinish.name());
|
||||
}
|
||||
|
||||
/**
|
||||
* 群发后的状态信息 为“send success”或“send fail”或“err(num)
|
||||
*/
|
||||
@XmlElement(name = "Status")
|
||||
private String status;
|
||||
/**
|
||||
* group_id下粉丝数;或者openid_list中的粉丝数
|
||||
*/
|
||||
@XmlElement(name = "TotalCount")
|
||||
private int totalCount;
|
||||
/**
|
||||
* 过滤(过滤是指特定地区、性别的过滤、用户设置拒收的过滤,用户接收已超4条的过滤)后,准备发送的粉丝数,原则上,FilterCount =
|
||||
* SentCount + ErrorCount
|
||||
*/
|
||||
@XmlElement(name = "FilterCount")
|
||||
private int filterCount;
|
||||
/**
|
||||
* 发送成功的粉丝数
|
||||
*/
|
||||
@XmlElement(name = "SentCount")
|
||||
private int sentCount;
|
||||
/**
|
||||
* 发送失败的粉丝数
|
||||
*/
|
||||
@XmlElement(name = "ErrorCount")
|
||||
private int errorCount;
|
||||
|
||||
public String getStatus() {
|
||||
return status;
|
||||
}
|
||||
|
||||
public int getTotalCount() {
|
||||
return totalCount;
|
||||
}
|
||||
|
||||
public int getFilterCount() {
|
||||
return filterCount;
|
||||
}
|
||||
|
||||
public int getSentCount() {
|
||||
return sentCount;
|
||||
}
|
||||
|
||||
public int getErrorCount() {
|
||||
return errorCount;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "MassEventMessage [status=" + status + ", totalCount="
|
||||
+ totalCount + ", filterCount=" + filterCount + ", sentCount="
|
||||
+ sentCount + ", errorCount=" + errorCount + ", "
|
||||
+ super.toString() + "]";
|
||||
}
|
||||
}
|
||||
|
||||
@ -14,7 +14,7 @@ import com.foxinmy.weixin4j.type.EventType;
|
||||
* @date 2014年4月6日
|
||||
* @since JDK 1.6
|
||||
* @see <a
|
||||
* href="http://mp.weixin.qq.com/wiki/2/5baf56ce4947d35003b86a9805634b1e.html#.E6.89.AB.E6.8F.8F.E5.B8.A6.E5.8F.82.E6.95.B0.E4.BA.8C.E7.BB.B4.E7.A0.81.E4.BA.8B.E4.BB.B6">扫描二维码事件</a>
|
||||
* href="https://mp.weixin.qq.com/wiki?t=resource/res_main&id=mp1421140454&token=&lang=zh_CN">扫描二维码事件</a>
|
||||
*/
|
||||
public class ScanEventMessage extends EventMessage {
|
||||
|
||||
|
||||
@ -10,7 +10,7 @@ import com.foxinmy.weixin4j.type.EventType;
|
||||
* @date 2014年4月6日
|
||||
* @since JDK 1.6
|
||||
* @see <a
|
||||
* href="http://mp.weixin.qq.com/wiki/2/5baf56ce4947d35003b86a9805634b1e.html#.E5.85.B3.E6.B3.A8.2F.E5.8F.96.E6.B6.88.E5.85.B3.E6.B3.A8.E4.BA.8B.E4.BB.B6">订阅号、服务号的关注/取消关注事件</a>
|
||||
* href="https://mp.weixin.qq.com/wiki?t=resource/res_main&id=mp1421140454&token=&lang=zh_CN">订阅号、服务号的关注/取消关注事件</a>
|
||||
*/
|
||||
public class ScribeEventMessage extends ScanEventMessage {
|
||||
|
||||
|
||||
@ -1,41 +1,41 @@
|
||||
package com.foxinmy.weixin4j.mp.event;
|
||||
|
||||
import javax.xml.bind.annotation.XmlElement;
|
||||
|
||||
import com.foxinmy.weixin4j.message.event.EventMessage;
|
||||
import com.foxinmy.weixin4j.type.EventType;
|
||||
|
||||
/**
|
||||
* 模板消息事件推送(公众平台)
|
||||
*
|
||||
* @className TemplatesendjobfinishMessage
|
||||
* @author jy
|
||||
* @date 2014年9月19日
|
||||
* @since JDK 1.6
|
||||
* @see <a
|
||||
* href="http://mp.weixin.qq.com/wiki/17/304c1885ea66dbedf7dc170d84999a9d.html#.E4.BA.8B.E4.BB.B6.E6.8E.A8.E9.80.81">模板消息事件推送</a>
|
||||
*/
|
||||
public class TemplatesendjobfinishMessage extends EventMessage {
|
||||
|
||||
private static final long serialVersionUID = -2903359365988594012L;
|
||||
|
||||
public TemplatesendjobfinishMessage() {
|
||||
super(EventType.templatesendjobfinish.name());
|
||||
}
|
||||
|
||||
/**
|
||||
* 推送状态 如failed: system failed
|
||||
*/
|
||||
@XmlElement(name = "Status")
|
||||
private String status;
|
||||
|
||||
public String getStatus() {
|
||||
return status;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "TemplatesendjobfinishMessage [status=" + status + ", "
|
||||
+ super.toString() + "]";
|
||||
}
|
||||
}
|
||||
package com.foxinmy.weixin4j.mp.event;
|
||||
|
||||
import javax.xml.bind.annotation.XmlElement;
|
||||
|
||||
import com.foxinmy.weixin4j.message.event.EventMessage;
|
||||
import com.foxinmy.weixin4j.type.EventType;
|
||||
|
||||
/**
|
||||
* 模板消息事件推送(公众平台)
|
||||
*
|
||||
* @className TemplatesendjobfinishMessage
|
||||
* @author jy
|
||||
* @date 2014年9月19日
|
||||
* @since JDK 1.6
|
||||
* @see <a
|
||||
* href="https://mp.weixin.qq.com/wiki?t=resource/res_main&id=mp1433751277&token=&lang=zh_CN">模板消息事件推送</a>
|
||||
*/
|
||||
public class TemplatesendjobfinishMessage extends EventMessage {
|
||||
|
||||
private static final long serialVersionUID = -2903359365988594012L;
|
||||
|
||||
public TemplatesendjobfinishMessage() {
|
||||
super(EventType.templatesendjobfinish.name());
|
||||
}
|
||||
|
||||
/**
|
||||
* 推送状态 如failed: system failed
|
||||
*/
|
||||
@XmlElement(name = "Status")
|
||||
private String status;
|
||||
|
||||
public String getStatus() {
|
||||
return status;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "TemplatesendjobfinishMessage [status=" + status + ", "
|
||||
+ super.toString() + "]";
|
||||
}
|
||||
}
|
||||
|
||||
@ -1,49 +1,49 @@
|
||||
package com.foxinmy.weixin4j.mp.event;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
import javax.xml.bind.annotation.XmlElement;
|
||||
import javax.xml.bind.annotation.XmlTransient;
|
||||
|
||||
import com.foxinmy.weixin4j.message.event.EventMessage;
|
||||
import com.foxinmy.weixin4j.type.EventType;
|
||||
|
||||
/**
|
||||
* 认证通知(资质认证成功/名称认证成功/年审通知/认证过期失效通知)
|
||||
*
|
||||
* @className VerifyExpireEventMessage
|
||||
* @author jy
|
||||
* @date 2015年10月25日
|
||||
* @since JDK 1.6
|
||||
* @see <a
|
||||
* href="http://mp.weixin.qq.com/wiki/1/7f81dec16b801b34629091094c099439.html">认证事件</a>
|
||||
*/
|
||||
public class VerifyExpireEventMessage extends EventMessage {
|
||||
|
||||
private static final long serialVersionUID = -4309074299189681095L;
|
||||
|
||||
public VerifyExpireEventMessage() {
|
||||
super(EventType.annual_renew.name());
|
||||
}
|
||||
|
||||
/**
|
||||
* 有效期 (整形),指的是时间戳,将于该时间戳认证过期
|
||||
*/
|
||||
@XmlElement(name = "EventKey")
|
||||
private long expiredTime;
|
||||
|
||||
public long getExpiredTime() {
|
||||
return expiredTime;
|
||||
}
|
||||
|
||||
@XmlTransient
|
||||
public Date getFormatExpiredTime() {
|
||||
return new Date(expiredTime * 1000l);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "VerifyExpireEventMessage [expiredTime=" + expiredTime + ", "
|
||||
+ super.toString() + "]";
|
||||
}
|
||||
}
|
||||
package com.foxinmy.weixin4j.mp.event;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
import javax.xml.bind.annotation.XmlElement;
|
||||
import javax.xml.bind.annotation.XmlTransient;
|
||||
|
||||
import com.foxinmy.weixin4j.message.event.EventMessage;
|
||||
import com.foxinmy.weixin4j.type.EventType;
|
||||
|
||||
/**
|
||||
* 认证通知(资质认证成功/名称认证成功/年审通知/认证过期失效通知)
|
||||
*
|
||||
* @className VerifyExpireEventMessage
|
||||
* @author jy
|
||||
* @date 2015年10月25日
|
||||
* @since JDK 1.6
|
||||
* @see <a
|
||||
* href="https://mp.weixin.qq.com/wiki?t=resource/res_main&id=mp1455785130&token=&lang=zh_CN">认证事件</a>
|
||||
*/
|
||||
public class VerifyExpireEventMessage extends EventMessage {
|
||||
|
||||
private static final long serialVersionUID = -4309074299189681095L;
|
||||
|
||||
public VerifyExpireEventMessage() {
|
||||
super(EventType.annual_renew.name());
|
||||
}
|
||||
|
||||
/**
|
||||
* 有效期 (整形),指的是时间戳,将于该时间戳认证过期
|
||||
*/
|
||||
@XmlElement(name = "EventKey")
|
||||
private long expiredTime;
|
||||
|
||||
public long getExpiredTime() {
|
||||
return expiredTime;
|
||||
}
|
||||
|
||||
@XmlTransient
|
||||
public Date getFormatExpiredTime() {
|
||||
return new Date(expiredTime * 1000l);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "VerifyExpireEventMessage [expiredTime=" + expiredTime + ", "
|
||||
+ super.toString() + "]";
|
||||
}
|
||||
}
|
||||
|
||||
@ -1,53 +1,55 @@
|
||||
package com.foxinmy.weixin4j.mp.event;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
import javax.xml.bind.annotation.XmlElement;
|
||||
import javax.xml.bind.annotation.XmlTransient;
|
||||
|
||||
/**
|
||||
* 认证失败事件(资质认证失败/名称认证失败)
|
||||
*
|
||||
* @className VerifyFailEventMessage
|
||||
* @author jy
|
||||
* @date 2015年10月25日
|
||||
* @since JDK 1.6
|
||||
* @see
|
||||
*/
|
||||
public class VerifyFailEventMessage extends VerifyExpireEventMessage {
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
private static final long serialVersionUID = 2155899086751787490L;
|
||||
|
||||
/**
|
||||
* 失败发生时间 (整形),时间戳
|
||||
*/
|
||||
@XmlElement(name = "FailTime")
|
||||
private long failTime;
|
||||
/**
|
||||
* 认证失败的原因
|
||||
*/
|
||||
@XmlElement(name = "FailReason")
|
||||
private String failReason;
|
||||
|
||||
public long getFailTime() {
|
||||
return failTime;
|
||||
}
|
||||
|
||||
@XmlTransient
|
||||
public Date getFormatFailTime() {
|
||||
return new Date(failTime * 1000l);
|
||||
}
|
||||
|
||||
public String getFailReason() {
|
||||
return failReason;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "VerifyFailEventMessage [failTime=" + failTime + ", failReason="
|
||||
+ failReason + ", " + super.toString() + "]";
|
||||
}
|
||||
}
|
||||
package com.foxinmy.weixin4j.mp.event;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
import javax.xml.bind.annotation.XmlElement;
|
||||
import javax.xml.bind.annotation.XmlTransient;
|
||||
|
||||
/**
|
||||
* 认证失败事件(资质认证失败/名称认证失败)
|
||||
*
|
||||
* @className VerifyFailEventMessage
|
||||
* @author jy
|
||||
* @date 2015年10月25日
|
||||
* @since JDK 1.6
|
||||
* @see <a href=
|
||||
* "https://mp.weixin.qq.com/wiki?t=resource/res_main&id=mp1455785130&token=&lang=zh_CN">
|
||||
* 认证事件</a>
|
||||
*/
|
||||
public class VerifyFailEventMessage extends VerifyExpireEventMessage {
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
private static final long serialVersionUID = 2155899086751787490L;
|
||||
|
||||
/**
|
||||
* 失败发生时间 (整形),时间戳
|
||||
*/
|
||||
@XmlElement(name = "FailTime")
|
||||
private long failTime;
|
||||
/**
|
||||
* 认证失败的原因
|
||||
*/
|
||||
@XmlElement(name = "FailReason")
|
||||
private String failReason;
|
||||
|
||||
public long getFailTime() {
|
||||
return failTime;
|
||||
}
|
||||
|
||||
@XmlTransient
|
||||
public Date getFormatFailTime() {
|
||||
return new Date(failTime * 1000l);
|
||||
}
|
||||
|
||||
public String getFailReason() {
|
||||
return failReason;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "VerifyFailEventMessage [failTime=" + failTime + ", failReason=" + failReason + ", " + super.toString()
|
||||
+ "]";
|
||||
}
|
||||
}
|
||||
|
||||
@ -1,39 +1,39 @@
|
||||
package com.foxinmy.weixin4j.response;
|
||||
|
||||
|
||||
/**
|
||||
* 微信被动消息回复
|
||||
*
|
||||
* @className WeixinResponse
|
||||
* @author jy
|
||||
* @date 2015年5月5日
|
||||
* @since JDK 1.6
|
||||
* @see TextResponse
|
||||
* @see ImageResponse
|
||||
* @see MusicResponse
|
||||
* @see VoiceResponse
|
||||
* @see VideoResponse
|
||||
* @see NewsResponse
|
||||
* @see TransferCustomerResponse
|
||||
* @see SingleResponse
|
||||
* @see BlankResponse
|
||||
* @see <a href=
|
||||
* "http://mp.weixin.qq.com/wiki/9/2c15b20a16019ae613d413e30cac8ea1.html">订阅号、服务号的被动响应消息</a>
|
||||
* @see <a
|
||||
* href="http://qydev.weixin.qq.com/wiki/index.php?title=%E8%A2%AB%E5%8A%A8%E5%93%8D%E5%BA%94%E6%B6%88%E6%81%AF">企业号的被动响应消息</a>
|
||||
*/
|
||||
public interface WeixinResponse {
|
||||
/**
|
||||
* 回复的消息类型
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public String getMsgType();
|
||||
|
||||
/**
|
||||
* 回复的消息内容
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public String toContent();
|
||||
}
|
||||
package com.foxinmy.weixin4j.response;
|
||||
|
||||
|
||||
/**
|
||||
* 微信被动消息回复
|
||||
*
|
||||
* @className WeixinResponse
|
||||
* @author jy
|
||||
* @date 2015年5月5日
|
||||
* @since JDK 1.6
|
||||
* @see TextResponse
|
||||
* @see ImageResponse
|
||||
* @see MusicResponse
|
||||
* @see VoiceResponse
|
||||
* @see VideoResponse
|
||||
* @see NewsResponse
|
||||
* @see TransferCustomerResponse
|
||||
* @see SingleResponse
|
||||
* @see BlankResponse
|
||||
* @see <a href=
|
||||
* "http://https://mp.weixin.qq.com/wiki?t=resource/res_main&id=mp1421140543&token=&lang=zh_CN">订阅号、服务号的被动响应消息</a>
|
||||
* @see <a
|
||||
* href="http://qydev.weixin.qq.com/wiki/index.php?title=%E8%A2%AB%E5%8A%A8%E5%93%8D%E5%BA%94%E6%B6%88%E6%81%AF">企业号的被动响应消息</a>
|
||||
*/
|
||||
public interface WeixinResponse {
|
||||
/**
|
||||
* 回复的消息类型
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public String getMsgType();
|
||||
|
||||
/**
|
||||
* 回复的消息内容
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public String toContent();
|
||||
}
|
||||
|
||||
@ -26,7 +26,7 @@ public final class MessageUtil {
|
||||
* @return 开发者通过检验signature对请求进行相关校验。若确认此次GET请求来自微信服务器
|
||||
* 请原样返回echostr参数内容,则接入生效 成为开发者成功,否则接入失败
|
||||
* @see <a
|
||||
* href="http://mp.weixin.qq.com/wiki/0/61c3a8b9d50ac74f18bdf2e54ddfc4e0.html">接入指南</a>
|
||||
* href="https://mp.weixin.qq.com/wiki?t=resource/res_main&id=mp1421135319&token=&lang=zh_CN">接入指南</a>
|
||||
*/
|
||||
public static String signature(String... para) {
|
||||
Arrays.sort(para);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user