cacheStorager) {
20 | super(thirdId, thirdSecret, cacheStorager);
21 | this.authAppId = authAppId;
22 | }
23 |
24 | /**
25 | * 获取永久授权码的key
26 | *
27 | * @return
28 | */
29 | @Override
30 | public String getCacheKey() {
31 | return String.format("%sthird_party_percode_ticket_%s_%s",
32 | TokenCreator.CACHEKEY_PREFIX, getThirdId(), authAppId);
33 | }
34 |
35 | public String getAuthAppId() {
36 | return authAppId;
37 | }
38 | }
39 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/tuple/ChatTuple.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.tuple;
2 |
3 | /**
4 | * 企业号会话消息元件
5 | *
6 | * @className ChatTuple
7 | * @author jinyu(foxinmy@gmail.com)
8 | * @date 2015年8月1日
9 | * @since JDK 1.6
10 | * @see com.foxinmy.weixin4j.tuple.Text
11 | * @see com.foxinmy.weixin4j.tuple.Image
12 | * @see com.foxinmy.weixin4j.tuple.File
13 | */
14 | public interface ChatTuple extends Tuple {
15 |
16 | }
17 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/tuple/MassTuple.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.tuple;
2 |
3 |
4 | /**
5 | * 群发消息元件
6 | *
7 | * @className MassTuple
8 | * @author jinyu(foxinmy@gmail.com)
9 | * @date 2014年11月22日
10 | * @since JDK 1.6
11 | * @see com.foxinmy.weixin4j.tuple.Text
12 | * @see com.foxinmy.weixin4j.tuple.Image
13 | * @see com.foxinmy.weixin4j.tuple.Voice
14 | * @see com.foxinmy.weixin4j.tuple.MpVideo
15 | * @see com.foxinmy.weixin4j.tuple.MpNews
16 | * @see com.foxinmy.weixin4j.tuple.Card
17 | */
18 | public interface MassTuple extends Tuple {
19 |
20 | }
21 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/tuple/NotifyTuple.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.tuple;
2 |
3 | /**
4 | * 客服消息元件
5 | *
6 | * @className NotifyTuple
7 | * @author jinyu(foxinmy@gmail.com)
8 | * @date 2014年11月22日
9 | * @since JDK 1.6
10 | * @see com.foxinmy.weixin4j.tuple.Text
11 | * @see com.foxinmy.weixin4j.tuple.Image
12 | * @see com.foxinmy.weixin4j.tuple.Voice
13 | * @see com.foxinmy.weixin4j.tuple.Video
14 | * @see com.foxinmy.weixin4j.tuple.Music
15 | * @see com.foxinmy.weixin4j.tuple.File
16 | * @see com.foxinmy.weixin4j.tuple.News
17 | * @see com.foxinmy.weixin4j.tuple.MpNews
18 | */
19 | public interface NotifyTuple extends Tuple {
20 |
21 | }
22 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/tuple/README.md:
--------------------------------------------------------------------------------
1 | 不同的消息类型中的消息对象
2 |
3 | [被动消息](http://mp.weixin.qq.com/wiki/14/89b871b5466b19b3efa4ada8e577d45e.html)
4 |
5 | [客服消息](http://mp.weixin.qq.com/wiki/1/70a29afed17f56d537c833f89be979c9.html#.E5.AE.A2.E6.9C.8D.E6.8E.A5.E5.8F.A3-.E5.8F.91.E6.B6.88.E6.81.AF)
6 |
7 | [群发消息](http://mp.weixin.qq.com/wiki/15/5380a4e6f02f2ffdc7981a8ed7a40753.html)
8 |
9 | [模板消息](http://mp.weixin.qq.com/wiki/17/304c1885ea66dbedf7dc170d84999a9d.html)
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/tuple/Text.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.tuple;
2 |
3 | import com.alibaba.fastjson.annotation.JSONCreator;
4 | import com.alibaba.fastjson.annotation.JSONField;
5 |
6 | /**
7 | * 文本对象
8 | *
9 | * 可用于「客服消息」「群发消息」及企业号的「聊天消息」
10 | *
11 | *
12 | * @className Text
13 | * @author jinyu(foxinmy@gmail.com)
14 | * @date 2014年9月29日
15 | * @since JDK 1.6
16 | * @see
17 | */
18 | public class Text implements MassTuple, NotifyTuple, ChatTuple {
19 |
20 | private static final long serialVersionUID = 520050144519064503L;
21 |
22 | @Override
23 | public String getMessageType() {
24 | return "text";
25 | }
26 |
27 | /**
28 | * 内容
29 | */
30 | private String content;
31 |
32 | @JSONCreator
33 | public Text(@JSONField(name = "content") String content) {
34 | this.content = content;
35 | }
36 |
37 | public String getContent() {
38 | return content;
39 | }
40 |
41 | @Override
42 | public String toString() {
43 | return "Text [content=" + content + "]";
44 | }
45 | }
46 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/tuple/Tuple.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.tuple;
2 |
3 | import java.io.Serializable;
4 |
5 | import javax.xml.bind.annotation.XmlTransient;
6 |
7 | /**
8 | * 消息元件
9 | *
10 | * @className Tuple
11 | * @author jinyu(foxinmy@gmail.com)
12 | * @date 2015年4月19日
13 | * @since JDK 1.6
14 | * @see
15 | */
16 | public interface Tuple extends Serializable {
17 |
18 | /**
19 | * 消息类型
20 | *
21 | * @return
22 | */
23 | @XmlTransient
24 | public String getMessageType();
25 | }
26 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/tuple/Voice.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.tuple;
2 |
3 | import com.alibaba.fastjson.annotation.JSONCreator;
4 | import com.alibaba.fastjson.annotation.JSONField;
5 |
6 | /**
7 | * 语音对象
8 | *
9 | * 可用于「客服消息」「群发消息」
10 | *
11 | *
12 | * @className Voice
13 | * @author jinyu(foxinmy@gmail.com)
14 | * @date 2014年9月29日
15 | * @since JDK 1.6
16 | * @see
17 | */
18 | public class Voice extends Image implements NotifyTuple {
19 |
20 | private static final long serialVersionUID = 8853054484809101524L;
21 |
22 | @Override
23 | public String getMessageType() {
24 | return "voice";
25 | }
26 |
27 | @JSONCreator
28 | public Voice(@JSONField(name = "mediaId") String mediaId) {
29 | super(mediaId);
30 | }
31 | }
32 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/CredentialType.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type;
2 |
3 | /**
4 | * 证件类型
5 | *
6 | * @className CredentialType
7 | * @author jinyu(foxinmy@gmail.com)
8 | * @date 2016年3月27日
9 | * @since JDK 1.6
10 | * @see
11 | * @deprecated 迁移到子模块weixin4j-pay
12 | */
13 | @Deprecated
14 | public enum CredentialType {
15 | IDCARD("身份证");
16 | CredentialType(String name) {
17 | this.name = name;
18 | }
19 |
20 | private String name;
21 |
22 | public String getName() {
23 | return this.name;
24 | }
25 | }
26 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/CurrencyType.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type;
2 |
3 | /**
4 | * 币种
5 | *
6 | * @className CurrencyType
7 | * @author jinyu(foxinmy@gmail.com)
8 | * @date 2014年11月2日
9 | * @since JDK 1.6
10 | * @see
11 | * @deprecated 迁移到子模块weixin4j-pay
12 | */
13 | @Deprecated
14 | public enum CurrencyType {
15 | CNY("人民币"), HKD("港元"), TWD("台币"), EUR("欧元"), USD("美元"), GBP("英镑"), JPY("日元"), CAD(
16 | "加拿大元"), AUD("澳大利亚元"), NZD("新西兰元"), KRW("韩元"), THB("泰铢");
17 |
18 | private String desc;
19 |
20 | CurrencyType(String desc) {
21 | this.desc = desc;
22 | }
23 |
24 | public String getDesc() {
25 | return desc;
26 | }
27 | }
28 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/CustomsCity.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type;
2 |
3 | /**
4 | * 海关
5 | *
6 | * @className CustomsCity
7 | * @author jinyu(foxinmy@gmail.com)
8 | * @date 2016年3月27日
9 | * @since JDK 1.6
10 | * @see
11 | * @deprecated 迁移到子模块weixin4j-pay
12 | */
13 | @Deprecated
14 | public enum CustomsCity {
15 | NO("无需上报海关"), GUANGZHOU("广州"), HANGZHOU("杭州"), NINGBO("宁波"), ZHENGZHOU_BS(
16 | "郑州(保税物流中心)"), CHONGQING("重庆"), XIAN("西安"), SHANGHAI("上海"), ZHENGZHOU_ZH(
17 | "郑州(综保区)");
18 |
19 | private String name;
20 |
21 | CustomsCity(String name) {
22 | this.name = name;
23 | }
24 |
25 | public String getName() {
26 | return this.name;
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/CustomsSatus.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type;
2 |
3 | /**
4 | * 报关状态
5 | *
6 | * @className CustomsSatus
7 | * @author jinyu(foxinmy@gmail.com)
8 | * @date 2016年3月27日
9 | * @since JDK 1.6
10 | * @see
11 | * @deprecated 迁移到子模块weixin4j-pay
12 | */
13 | @Deprecated
14 | public enum CustomsSatus {
15 | UNDECLARED("未申报"), SUBMITTED("申报已提交"), PROCESSING("申报中"), SUCCESS("申报成功"), FAIL(
16 | "申报失败"), EXCEPT("海关接口异常");
17 | private String sate;
18 |
19 | CustomsSatus(String sate) {
20 | this.sate = sate;
21 | }
22 |
23 | public String getSate() {
24 | return this.sate;
25 | }
26 | }
27 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/Gender.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type;
2 |
3 | /**
4 | * 用户性别
5 | *
6 | * @className Gender
7 | * @author jinyu(foxinmy@gmail.com)
8 | * @date 2014年11月5日
9 | * @since JDK 1.6
10 | * @see
11 | */
12 | public enum Gender {
13 | /**
14 | * 男
15 | */
16 | male,
17 | /**
18 | * 女
19 | */
20 | female,
21 | /**
22 | * 未知
23 | */
24 | unknown;
25 | }
26 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/IdQuery.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type;
2 |
3 | import java.io.Serializable;
4 |
5 | /**
6 | * ID查询
7 | *
8 | * @className IdQuery
9 | * @author jinyu(foxinmy@gmail.com)
10 | * @date 2014年11月1日
11 | * @since JDK 1.6
12 | * @see
13 | * @deprecated 迁移到子模块weixin4j-pay
14 | */
15 | @Deprecated
16 | public class IdQuery implements Serializable {
17 |
18 | private static final long serialVersionUID = -5273675987521807370L;
19 | /**
20 | * id值
21 | */
22 | private String id;
23 | /**
24 | * id类型
25 | *
26 | * @see com.foxinmy.weixin4j.type.IdType
27 | */
28 | private IdType type;
29 |
30 | public IdQuery(String id, IdType idType) {
31 | this.id = id;
32 | this.type = idType;
33 | }
34 |
35 | public String getId() {
36 | return id;
37 | }
38 |
39 | public IdType getType() {
40 | return type;
41 | }
42 |
43 | @Override
44 | public String toString() {
45 | return String.format("%s=%s", type.getName(), id);
46 | }
47 | }
48 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/IdType.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type;
2 |
3 | /**
4 | * ID类型
5 | *
6 | * @className IdType
7 | * @author jinyu(foxinmy@gmail.com)
8 | * @date 2014年11月1日
9 | * @since JDK 1.6
10 | * @see
11 | * @deprecated 迁移到子模块weixin4j-pay
12 | */
13 | @Deprecated
14 | public enum IdType {
15 | /**
16 | * 微信退款单号
17 | */
18 | REFUNDID("refund_id"),
19 | /**
20 | * 微信订单号
21 | */
22 | TRANSACTIONID("transaction_id"),
23 | /**
24 | * 商户订单号
25 | */
26 | TRADENO("out_trade_no"),
27 | /**
28 | * 商户退款号
29 | */
30 | REFUNDNO("out_refund_no"),
31 | /**
32 | * 商户子订单号
33 | */
34 | SUBORDERNO("sub_order_no"),
35 | /**
36 | * 微信子订单号
37 | */
38 | SUBORDERID("sub_order_id");
39 | private String name;
40 |
41 | IdType(String name) {
42 | this.name = name;
43 | }
44 |
45 | public String getName() {
46 | return name;
47 | }
48 | }
49 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/QRType.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type;
2 |
3 | /**
4 | * 二维码类型
5 | *
6 | * @className QRType
7 | * @author jinyu(foxinmy@gmail.com)
8 | * @date 2014年11月4日
9 | * @since JDK 1.6
10 | * @see
11 | */
12 | public enum QRType {
13 | /**
14 | * 临时二维码
15 | */
16 | QR_SCENE,
17 | /**
18 | * 永久二维码(场景值为数字范围在1-100000之间)
19 | */
20 | QR_LIMIT_SCENE,
21 | /**
22 | * 永久二维码(场景值为字符串长度在1-64之间)
23 | */
24 | QR_LIMIT_STR_SCENE,
25 | /**
26 | * 卡券二维码:单个卡券
27 | */
28 | QR_CARD,
29 | /**
30 | * 临时的字符串参数值
31 | */
32 | QR_STR_SCENE,
33 | /**
34 | * 卡券二维码:多个卡券
35 | */
36 | QR_MULTIPLE_CARD;
37 | }
38 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/SignType.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type;
2 |
3 | /**
4 | * 签名类型
5 | *
6 | * @className SignType
7 | * @author jinyu(foxinmy@gmail.com)
8 | * @date 2014年11月5日
9 | * @since JDK 1.6
10 | * @see
11 | * @deprecated 迁移到子模块weixin4j-pay
12 | */
13 | @Deprecated
14 | public enum SignType {
15 | SHA1, MD5, HMAC$SHA256
16 | }
17 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/TarType.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type;
2 |
3 | /**
4 | * 压缩类型
5 | *
6 | * @className TarType
7 | * @author jinyu(foxinmy@gmail.com)
8 | * @date 2016年12月21日
9 | * @since JDK 1.6
10 | * @see
11 | * @deprecated 迁移到子模块weixin4j-pay
12 | */
13 | @Deprecated
14 | public enum TarType {
15 | GZIP
16 | }
17 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/TicketType.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type;
2 |
3 | /**
4 | * 票据类型(一般用于JSSDK
5 | *
6 | * @className TicketType
7 | * @author jinyu(foxinmy@gmail.com)
8 | * @date 2015年12月25日
9 | * @since JDK 1.7
10 | * @see
11 | */
12 | public enum TicketType {
13 | /**
14 | * jsapi
15 | */
16 | jsapi,
17 | /**
18 | * 公众平台-卡券
19 | */
20 | wx_card,
21 | /**
22 | * 企业号-选取联系人
23 | */
24 | contact;
25 | }
26 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/TradeState.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type;
2 |
3 | /**
4 | * 交易状态
5 | *
6 | * @className TradeState
7 | * @author jinyu(foxinmy@gmail.com)
8 | * @date 2014年11月2日
9 | * @since JDK 1.6
10 | * @see
11 | * @deprecated 迁移到子模块weixin4j-pay
12 | */
13 | @Deprecated
14 | public enum TradeState {
15 | /**
16 | * 支付成功
17 | */
18 | SUCCESS,
19 | /**
20 | * 转入退款
21 | */
22 | REFUND,
23 | /**
24 | * 未支付
25 | */
26 | NOTPAY,
27 | /**
28 | * 已关闭
29 | */
30 | CLOSED,
31 | /**
32 | * 已撤销
33 | */
34 | REVOKED,
35 | /**
36 | * 用户支付中
37 | */
38 | USERPAYING,
39 | /**
40 | * 未支付(输入密码或 确认支付超时)
41 | */
42 | NOPAY,
43 | /**
44 | * 支付失败(其他 原因,如银行返回失败)
45 | */
46 | PAYERROR;
47 | }
48 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/TradeType.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type;
2 |
3 | /**
4 | * 微信支付类型
5 | *
6 | * @className TradeType
7 | * @author jinyu(foxinmy@gmail.com)
8 | * @date 2014年10月21日
9 | * @since JDK 1.6
10 | * @see
11 | * @deprecated 迁移到weixin4j-pay子模块
12 | */
13 | @Deprecated
14 | public enum TradeType {
15 | /**
16 | * JS支付
17 | */
18 | JSAPI,
19 | /**
20 | * 刷卡支付
21 | */
22 | MICROPAY,
23 | /**
24 | * 扫码支付
25 | */
26 | NATIVE,
27 | /**
28 | * APP支付
29 | */
30 | APP,
31 | /**
32 | * WAP支付
33 | */
34 | MWEB;
35 | }
36 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/Week.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type;
2 |
3 | /**
4 | * 星期
5 | *
6 | * @className Week
7 | * @author jinyu(foxinmy@gmail.com)
8 | * @date 2016年8月5日
9 | * @since JDK 1.6
10 | */
11 | public enum Week {
12 | MONDAY("周一"), TUESDAY("周二"), WEDNESDAY("周三"), THURSDAY("周四"), FRIDAY("周五"), SATURDAY(
13 | "周六"), SUNDAY("周日");
14 | private String desc;
15 |
16 | Week(String desc) {
17 | this.desc = desc;
18 | }
19 |
20 | public String getDesc() {
21 | return desc;
22 | }
23 | }
24 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/card/ActivateFormFieldType.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type.card;
2 |
3 | /**
4 | * 激活form表单字段类型
5 | *
6 | * @auther: Feng Yapeng
7 | * @since: 2016/12/20 15:34
8 | */
9 | public enum ActivateFormFieldType {
10 |
11 | FORM_FIELD_RADIO,/*自定义单选 */
12 |
13 | FORM_FIELD_SELECT,/*自定义选择项 */
14 |
15 | FORM_FIELD_CHECK_BOX,/*自定义多选*/;
16 | }
17 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/card/CardCodeType.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type.card;
2 |
3 | /**
4 | * 卡券码型
5 | *
6 | * @className CardCodeType
7 | * @author jinyu(foxinmy@gmail.com)
8 | * @date 2016年8月4日
9 | * @since JDK 1.7
10 | */
11 | public enum CardCodeType {
12 | /**
13 | * 文本
14 | */
15 | CODE_TYPE_TEXT,
16 | /**
17 | * 一维码
18 | */
19 | CODE_TYPE_BARCODE,
20 | /**
21 | * 二维码
22 | */
23 | CODE_TYPE_QRCODE,
24 | /**
25 | * 二维码无code显示
26 | */
27 | CODE_TYPE_ONLY_QRCODE,
28 | /**
29 | * 一维码无code显示
30 | */
31 | CODE_TYPE_ONLY_BARCODE,
32 | /**
33 | * 不显示code和条形码类型
34 | */
35 | CODE_TYPE_NONE;
36 | }
37 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/card/CardStatus.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type.card;
2 |
3 | /**
4 | * 会员卡的状态
5 | *
6 | * @auther: Feng Yapeng
7 | * @since: 2016/12/19 11:39
8 | */
9 | public enum CardStatus {
10 |
11 | /**
12 | * 待审核;
13 | */
14 | CARD_STATUS_NOT_VERIFY,
15 |
16 | /**
17 | * 审核失败
18 | */
19 | CARD_STATUS_VERIFY_FAIL,
20 |
21 | /**
22 | * 通过审核
23 | */
24 | CARD_STATUS_VERIFY_OK,
25 |
26 | /**
27 | * 卡券被商户删除
28 | */
29 | CARD_STATUS_DELETE,
30 |
31 | /**
32 | * 在公众平台投放过的卡券
33 | */
34 | CARD_STATUS_DISPATCH;
35 |
36 | }
37 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/card/CardType.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type.card;
2 |
3 | /**
4 | * 卡券类型
5 | *
6 | * @className CardType
7 | * @author jinyu(foxinmy@gmail.com)
8 | * @date 2016年4月4日
9 | * @since JDK 1.6
10 | * @see
11 | */
12 | public enum CardType {
13 | /**
14 | * 团购券
15 | */
16 | GROUPON,
17 | /**
18 | * 代金券
19 | */
20 | CASH,
21 | /**
22 | * 折扣券
23 | */
24 | DISCOUNT,
25 | /**
26 | * 兑换券
27 | */
28 | GIFT,
29 | /**
30 | * 优惠券
31 | */
32 | GENERAL_COUPON,
33 |
34 | /**
35 | * 会员卡
36 | */
37 | MEMBER_CARD,
38 |
39 | /**
40 | * 通用(礼品)卡
41 | */
42 | GENERAL_CARD
43 | }
44 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/card/FieldNameType.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type.card;
2 |
3 | /**
4 | * 会员信息类目半自定义名称
5 | *
6 | * @auther: Feng Yapeng
7 | * @since: 2016/12/15 10:37
8 | */
9 | public enum FieldNameType {
10 | /**
11 | * 等级
12 | */
13 | FIELD_NAME_TYPE_LEVEL,
14 | /**
15 | * 优惠券
16 | */
17 | FIELD_NAME_TYPE_COUPON,
18 | /**
19 | * 印花
20 | */
21 | FIELD_NAME_TYPE_STAMP,
22 | /**
23 | * 折扣
24 | */
25 | FIELD_NAME_TYPE_DISCOUNT,
26 | /**
27 | * 成就
28 | */
29 | FIELD_NAME_TYPE_ACHIEVEMEN,
30 | /**
31 | * 里程
32 | */
33 | FIELD_NAME_TYPE_MILEAGE,
34 | /**
35 | * 集点
36 | */
37 | FIELD_NAME_TYPE_SET_POINTS,
38 | /**
39 | * 次数
40 | */
41 | FIELD_NAME_TYPE_TIMS;
42 | }
43 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/card/SubCardType.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type.card;
2 |
3 | /**
4 | * 礼品卡类型
5 | *
6 | * @className SubCardType
7 | * @author kit(kit.li@qq.com)
8 | * @date 2018年10月23日
9 | */
10 | public enum SubCardType {
11 | /**
12 | * 礼品卡
13 | */
14 | GIFT_CARD,
15 | /**
16 | * 兑换卡
17 | */
18 | VOUCHER
19 | }
20 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/card/UserCardStatus.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type.card;
2 |
3 | /**
4 | * 用户的会员卡状态
5 | *
6 | * @auther: Feng Yapeng
7 | * @since: 2016/12/21 11:42
8 | */
9 | public enum UserCardStatus {
10 |
11 | NORMAL,//正常
12 | EXPIRE,//已过期
13 | GIFTING,// 转赠中
14 | GIFT_SUCC,// 转赠成功
15 | GIFT_TIMEOUT,// 转赠超时
16 | DELETE,//已删除
17 | UNAVAILABLE,//已失效
18 | ;
19 | }
20 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/mch/BillType.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type.mch;
2 |
3 | /**
4 | * 对账单类型
5 | *
6 | * @className BillType
7 | * @author jinyu(foxinmy@gmail.com)
8 | * @date 2014年10月31日
9 | * @since JDK 1.6
10 | * @see
11 | * @deprecated 迁移到子模块weixin4j-pay
12 | */
13 | @Deprecated
14 | public enum BillType {
15 | /**
16 | * 全部
17 | */
18 | ALL(0),
19 | /**
20 | * 成功订单
21 | */
22 | SUCCESS(1),
23 | /**
24 | * 退款订单
25 | */
26 | REFUND(2);
27 | private int val;
28 |
29 | BillType(int val) {
30 | this.val = val;
31 | }
32 |
33 | public int getVal() {
34 | return val;
35 | }
36 | }
37 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/mch/CorpPaymentCheckNameType.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type.mch;
2 |
3 | /**
4 | * 企业付款检查收款人姓名的策略
5 | *
6 | * @className CorpPaymentCheckNameType
7 | * @author jinyu(foxinmy@gmail.com)
8 | * @date 2015年4月1日
9 | * @since JDK 1.6
10 | * @see
11 | */
12 | @Deprecated
13 | public enum CorpPaymentCheckNameType {
14 | /**
15 | * 不校验真实姓名
16 | */
17 | NO_CHECK,
18 | /**
19 | * 强校验真实姓名(未实名认证的用户会校验失败,无法转账)
20 | */
21 | FORCE_CHECK,
22 | /**
23 | * 针对已实名认证的用户才校验真实姓名(未实名认证用户不校验,可以转账成功)
24 | */
25 | OPTION_CHECK;
26 | }
27 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/mch/CouponStatus.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type.mch;
2 |
3 | /**
4 | * 代金券状态
5 | *
6 | * @className CouponStatus
7 | * @author jinyu(foxinmy@gmail.com)
8 | * @date 2015年3月27日
9 | * @since JDK 1.6
10 | * @see
11 | * @deprecated 迁移到子模块weixin4j-pay
12 | */
13 | @Deprecated
14 | public enum CouponStatus {
15 | /**
16 | * 已激活
17 | */
18 | ACTIVATED(2),
19 | /**
20 | * 已锁定
21 | */
22 | LOCKED(4),
23 | /**
24 | * 已实扣
25 | */
26 | USED(8);
27 | private int val;
28 |
29 | CouponStatus(int val) {
30 | this.val = val;
31 | }
32 |
33 | public int getVal() {
34 | return val;
35 | }
36 | }
37 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/mch/CouponStockStatus.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type.mch;
2 |
3 | /**
4 | * 代金券批次状态
5 | *
6 | * @className CouponStockStatus
7 | * @author jinyu(foxinmy@gmail.com)
8 | * @date 2015年3月27日
9 | * @since JDK 1.6
10 | * @see
11 | * @deprecated 迁移到子模块weixin4j-pay
12 | */
13 | @Deprecated
14 | public enum CouponStockStatus {
15 | /**
16 | * 未激活
17 | */
18 | INACTIVE(1),
19 | /**
20 | * 审批中
21 | */
22 | APPROVAL_PROCESS(2),
23 | /**
24 | * 已激活
25 | */
26 | ACTIVATED(4),
27 | /**
28 | * 已作废
29 | */
30 | SUPERSEDED(8),
31 | /**
32 | * 中止发放
33 | */
34 | SUSPEND(16);
35 | private int val;
36 |
37 | CouponStockStatus(int val) {
38 | this.val = val;
39 | }
40 |
41 | public int getVal() {
42 | return val;
43 | }
44 | }
45 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/mch/CouponStockType.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type.mch;
2 |
3 | /**
4 | * 代金券批次类型
5 | *
6 | * @className CouponStockType
7 | * @author jinyu(foxinmy@gmail.com)
8 | * @date 2015年3月27日
9 | * @since JDK 1.6
10 | * @see
11 | * @deprecated 迁移到子模块weixin4j-pay
12 | */
13 | @Deprecated
14 | public enum CouponStockType {
15 | /**
16 | * 批量型
17 | */
18 | BATCH(1),
19 | /**
20 | * 触发型
21 | */
22 | TRIGGER(2);
23 | private int val;
24 |
25 | CouponStockType(int val) {
26 | this.val = val;
27 | }
28 |
29 | public int getVal() {
30 | return val;
31 | }
32 | }
33 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/mch/CouponType.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type.mch;
2 |
3 | /**
4 | * 代金券类型
5 | *
6 | * @className CouponType
7 | * @author jinyu(foxinmy@gmail.com)
8 | * @date 2015年3月27日
9 | * @since JDK 1.6
10 | * @see
11 | * @deprecated 迁移到子模块weixin4j-pay
12 | */
13 | @Deprecated
14 | public enum CouponType {
15 | /**
16 | * 使用无门槛
17 | */
18 | NO_THRESHOLD(1),
19 | /**
20 | * 使用有门槛
21 | */
22 | HAS_THRESHOLD(2),
23 | /**
24 | * 门槛叠加
25 | */
26 | THRESHOLD_PLUS(3),
27 |
28 | /**
29 | * 充值代金券
30 | */
31 | CASH(-1),
32 | /**
33 | * 非充值代金券
34 | */
35 | NO_CASH(-2);
36 | private int val;
37 |
38 | CouponType(int val) {
39 | this.val = val;
40 | }
41 |
42 | public int getVal() {
43 | return val;
44 | }
45 | }
46 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/mch/RedpacketSceneType.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type.mch;
2 |
3 | /**
4 | * 发放红包使用场景
5 | *
6 | * @className RedpacketSceneType
7 | * @author jinyu(foxinmy@gmail.com)
8 | * @date 2017年1月4日
9 | * @since JDK 1.6
10 | * @deprecated 迁移到子模块weixin4j-pay
11 | */
12 | @Deprecated
13 | public enum RedpacketSceneType {
14 | /**
15 | * 商品促销
16 | */
17 | PRODUCT_1,
18 | /**
19 | * 抽奖
20 | */
21 | PRODUCT_2,
22 | /**
23 | * 虚拟物品兑奖
24 | */
25 | PRODUCT_3,
26 | /**
27 | * 企业内部福利
28 | */
29 | PRODUCT_4,
30 | /**
31 | * 渠道分润
32 | */
33 | PRODUCT_5,
34 | /**
35 | * 保险回馈
36 | */
37 | PRODUCT_6,
38 | /**
39 | * 彩票派奖
40 | */
41 | PRODUCT_7,
42 | /**
43 | * 税务刮奖
44 | */
45 | PRODUCT_8
46 | }
47 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/mch/RedpacketSendType.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type.mch;
2 |
3 | /**
4 | * 红包发放类型
5 | *
6 | * @className RedpacketSendType
7 | * @author jinyu(foxinmy@gmail.com)
8 | * @date 2015年6月4日
9 | * @since JDK 1.6
10 | * @see
11 | * @deprecated 迁移到子模块weixin4j-pay
12 | */
13 | @Deprecated
14 | public enum RedpacketSendType {
15 | /**
16 | * 通过API接口发放
17 | */
18 | API,
19 | /**
20 | * 通过上传文件方式发放
21 | */
22 | UPLOAD,
23 | /**
24 | * 通过活动方式发放
25 | */
26 | ACTIVITY;
27 | }
28 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/mch/RedpacketStatus.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type.mch;
2 |
3 | /**
4 | * 红包状态
5 | * @className RedpacketStatus
6 | * @author jinyu(foxinmy@gmail.com)
7 | * @date 2015年6月4日
8 | * @since JDK 1.6
9 | * @see
10 | * @deprecated 迁移到子模块weixin4j-pay
11 | */
12 | @Deprecated
13 | public enum RedpacketStatus {
14 | /**
15 | * 发放中
16 | */
17 | SENDING,
18 | /**
19 | * 已发放待领取
20 | */
21 | SENT,
22 | /**
23 | * 发放失败
24 | */
25 | FAILED,
26 | /**
27 | * 已领取
28 | */
29 | RECEIVED,
30 | /**
31 | * 已退款
32 | */
33 | REFUND;
34 | }
35 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/mch/RedpacketType.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type.mch;
2 |
3 | /**
4 | * 红包类型
5 | *
6 | * @className RedpacketType
7 | * @author jinyu(foxinmy@gmail.com)
8 | * @date 2015年6月4日
9 | * @since JDK 1.6
10 | * @see
11 | * @deprecated 迁移到子模块weixin4j-pay
12 | */
13 | @Deprecated
14 | public enum RedpacketType {
15 | /**
16 | * 裂变红包
17 | */
18 | GROUP,
19 | /**
20 | * 普通红包
21 | */
22 | NORMAL;
23 | }
24 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/mch/RefundAccountType.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type.mch;
2 |
3 | /**
4 | * 退款资金来源
5 | * @className RefundAccountType
6 | * @author jinyu(foxinmy@gmail.com)
7 | * @date 2016年12月12日
8 | * @deprecated 迁移到子模块weixin4j-pay
9 | */
10 | @Deprecated
11 | public enum RefundAccountType {
12 | /**
13 | * ---未结算资金退款(默认使用未结算资金退款)
14 | */
15 | REFUND_SOURCE_UNSETTLED_FUNDS,
16 | /**
17 | * ---可用余额退款
18 | */
19 | REFUND_SOURCE_RECHARGE_FUNDS
20 | }
21 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/mch/RefundChannel.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type.mch;
2 |
3 | /**
4 | * 退款渠道
5 | *
6 | * @className RefundChannel
7 | * @author jinyu(foxinmy@gmail.com)
8 | * @date 2014年11月6日
9 | * @since JDK 1.6
10 | * @see
11 | * @deprecated 迁移到子模块weixin4j-pay
12 | */
13 | @Deprecated
14 | public enum RefundChannel {
15 | /**
16 | * 原路退款
17 | */
18 | ORIGINAL,
19 | /**
20 | * 退回到余额
21 | */
22 | BALANCE,
23 | /**
24 | * 财付通
25 | */
26 | TENPAY,
27 | /**
28 | * 银行
29 | */
30 | BANK,
31 | /**
32 | * 原账户异常退到其他余额账户
33 | */
34 | OTHER_BALANCE,
35 | /**
36 | * 原银行卡异常退到其他银行卡
37 | */
38 | OTHER_BANKCARD
39 | }
40 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/mch/RefundStatus.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type.mch;
2 |
3 | /**
4 | * 退款状态
5 | *
6 | * @className RefundStatus
7 | * @author jinyu(foxinmy@gmail.com)
8 | * @date 2014年11月2日
9 | * @since JDK 1.6
10 | * @see
11 | * @deprecated 迁移到子模块weixin4j-pay
12 | */
13 | @Deprecated
14 | public enum RefundStatus {
15 | /**
16 | * 退款成功
17 | */
18 | SUCCESS,
19 | /**
20 | * 退款失败
21 | */
22 | FAIL,
23 | /**
24 | * 退款处理中
25 | */
26 | PROCESSING,
27 | /**
28 | * 未确定,需要商户 原退款单号重新发起
29 | */
30 | NOTSURE,
31 | /**
32 | * 转入代发,退款到银行发现用户的卡作废或者冻结了,导致原路退款银行卡失败,资金回流到商户的现金帐号,需要商户人工干预,通过线下或者财付通转
33 | * 账的方式进行退款。
34 | */
35 | CHANGE;
36 | }
37 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/type/mch/RefundType.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.type.mch;
2 |
3 | /**
4 | * 退款类型
5 | *
6 | * @className RefundType
7 | * @author jinyu(foxinmy@gmail.com)
8 | * @date 2014年12月31日
9 | * @since JDK 1.6
10 | * @see
11 | * @deprecated 迁移到子模块weixin4j-pay
12 | */
13 | @Deprecated
14 | public enum RefundType {
15 | /**
16 | * 1:商户号余额退款;
17 | */
18 | BALANCE(1),
19 | /**
20 | * 2:现金帐号 退款;
21 | */
22 | CASH(2),
23 | /**
24 | * 3:优先商户号退款,若商户号余额不足, 再做现金帐号退款。 使用 2 或 3 时,需联系财 付通开通此功能
25 | */
26 | BOTH(3);
27 |
28 | private int val;
29 |
30 | RefundType(int val) {
31 | this.val = val;
32 | }
33 |
34 | public int getVal() {
35 | return val;
36 | }
37 | }
38 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/util/NameValue.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.util;
2 |
3 | import java.io.Serializable;
4 |
5 | import com.alibaba.fastjson.annotation.JSONCreator;
6 | import com.alibaba.fastjson.annotation.JSONField;
7 |
8 | /**
9 | * name-value
10 | *
11 | * @className NameValue
12 | * @author jinyu(foxinmy@gmail.com)
13 | * @date 2015年3月29日
14 | * @since JDK 1.6
15 | * @see
16 | */
17 | public class NameValue implements Serializable {
18 |
19 | private static final long serialVersionUID = -348620146718819093L;
20 | private String name;
21 | private String value;
22 |
23 | @JSONCreator
24 | public NameValue(@JSONField(name = "name") String name,
25 | @JSONField(name = "value") String value) {
26 | this.name = name;
27 | this.value = value;
28 | }
29 |
30 | public String getName() {
31 | return name;
32 | }
33 |
34 | public String getValue() {
35 | return value;
36 | }
37 |
38 | @Override
39 | public String toString() {
40 | return "NameValue [name=" + name + ", value=" + value + "]";
41 | }
42 | }
43 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/util/RegexUtil.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.util;
2 |
3 | import java.util.regex.Matcher;
4 | import java.util.regex.Pattern;
5 |
6 | /**
7 | * 正则表达式工具类
8 | *
9 | * @className RegexUtil
10 | * @author jinyu(foxinmy@gmail.com)
11 | * @date 2015年12月8日
12 | * @since JDK 1.7
13 | * @see
14 | */
15 | public final class RegexUtil {
16 | /**
17 | * Content-disposition 中的 filename提取正则
18 | */
19 | private static final Pattern FILENAME_RGX = Pattern
20 | .compile("(?<=filename=\").*?(?=\")");
21 |
22 | /**
23 | * 从 Content-disposition提取文件名
24 | *
25 | * @param contentDisposition
26 | * @return
27 | */
28 | public static String regexFileNameFromContentDispositionHeader(
29 | String contentDisposition) {
30 | if (StringUtil.isBlank(contentDisposition)) {
31 | return null;
32 | }
33 | Matcher filenameMatcher = FILENAME_RGX.matcher(contentDisposition);
34 | return filenameMatcher.find() ? filenameMatcher.group() : null;
35 | }
36 | }
37 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/xml/ListWrapper.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.xml;
2 |
3 | import java.io.Serializable;
4 | import java.util.ArrayList;
5 | import java.util.List;
6 |
7 | import javax.xml.bind.annotation.XmlAnyElement;
8 |
9 | public class ListWrapper implements Serializable {
10 |
11 | private static final long serialVersionUID = 7550802632983954221L;
12 |
13 | private List items;
14 |
15 | public ListWrapper() {
16 | items = new ArrayList();
17 | }
18 |
19 | @XmlAnyElement(lax = true)
20 | public List getItems() {
21 | return items;
22 | }
23 | }
24 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/java/com/foxinmy/weixin4j/xml/ListsuffixResult.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.xml;
2 |
3 | import java.lang.annotation.ElementType;
4 | import java.lang.annotation.Retention;
5 | import java.lang.annotation.RetentionPolicy;
6 | import java.lang.annotation.Target;
7 |
8 | /**
9 | * 对$n结尾的节点注解
10 | *
11 | * @className ListsuffixResult
12 | * @author jinyu(foxinmy@gmail.com)
13 | * @date 2015年6月15日
14 | * @since JDK 1.6
15 | * @see
16 | */
17 | @Target(ElementType.FIELD)
18 | @Retention(RetentionPolicy.RUNTIME)
19 | public @interface ListsuffixResult {
20 | String[] value() default { "(_\\d)$" };
21 | }
22 |
--------------------------------------------------------------------------------
/weixin4j-base/src/main/resources/com/foxinmy/weixin4j/weixin4j.properties:
--------------------------------------------------------------------------------
1 | weixin4j.name=weixin4j
2 | weixin4j.version=${project.version}
3 |
--------------------------------------------------------------------------------
/weixin4j-base/src/test/java/com/foxinmy/weixin4j/api/MchApiTest.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.api;
2 |
3 | import static org.junit.Assert.assertNotNull;
4 |
5 | import org.junit.Test;
6 |
7 | import com.foxinmy.weixin4j.model.WeixinPayAccount;
8 |
9 | public class MchApiTest {
10 |
11 | @Test
12 | public void testWeixinBundle() {
13 | MchApi mchApi = new MchApi(new WeixinPayAccount(null, null, null));
14 | assertNotNull(mchApi.weixinBundle());
15 | }
16 |
17 | }
18 |
--------------------------------------------------------------------------------
/weixin4j-base/src/test/java/com/foxinmy/weixin4j/base/test/http/Apache3HttpClientTest.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.base.test.http;
2 |
3 | import com.foxinmy.weixin4j.http.factory.HttpClientFactory;
4 | import com.foxinmy.weixin4j.http.support.apache3.HttpComponent3Factory;
5 |
6 | /**
7 | * Apache3 for http test
8 | *
9 | * @className Apache3HttpClientTest
10 | * @author jinyu(foxinmy@gmail.com)
11 | * @date 2016年7月28日
12 | * @since JDK 1.6
13 | */
14 | public class Apache3HttpClientTest extends HttpClientTest {
15 |
16 | @Override
17 | protected HttpClientFactory createHttpFactory() {
18 | return new HttpComponent3Factory();
19 | }
20 | }
21 |
--------------------------------------------------------------------------------
/weixin4j-base/src/test/java/com/foxinmy/weixin4j/base/test/http/Apache4_1HttpClientTest.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.base.test.http;
2 |
3 | import com.foxinmy.weixin4j.http.factory.HttpClientFactory;
4 | import com.foxinmy.weixin4j.http.support.apache4.HttpComponent4_1Factory;
5 |
6 | /**
7 | * Apache4 for http test
8 | * @className Apache4HttpClientTest
9 | * @author jinyu(foxinmy@gmail.com)
10 | * @date 2016年7月28日
11 | * @since JDK 1.6
12 | */
13 | public class Apache4_1HttpClientTest extends HttpClientTest {
14 |
15 | @Override
16 | protected HttpClientFactory createHttpFactory() {
17 | return new HttpComponent4_1Factory();
18 | }
19 | }
20 |
--------------------------------------------------------------------------------
/weixin4j-base/src/test/java/com/foxinmy/weixin4j/base/test/http/Apache4_2HttpClientTest.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.base.test.http;
2 |
3 | import com.foxinmy.weixin4j.http.factory.HttpClientFactory;
4 | import com.foxinmy.weixin4j.http.support.apache4.HttpComponent4_2Factory;
5 |
6 | /**
7 | * Apache4 for http test
8 | * @className Apache4HttpClientTest
9 | * @author jinyu(foxinmy@gmail.com)
10 | * @date 2016年7月28日
11 | * @since JDK 1.6
12 | */
13 | public class Apache4_2HttpClientTest extends HttpClientTest {
14 |
15 | @Override
16 | protected HttpClientFactory createHttpFactory() {
17 | return new HttpComponent4_2Factory();
18 | }
19 | }
20 |
--------------------------------------------------------------------------------
/weixin4j-base/src/test/java/com/foxinmy/weixin4j/base/test/http/NettyHttpClientTest.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.base.test.http;
2 |
3 | import com.foxinmy.weixin4j.http.factory.HttpClientFactory;
4 | import com.foxinmy.weixin4j.http.support.netty.Netty4HttpClientFactory;
5 |
6 | /**
7 | * Netty for http test
8 | * @className NettyHttpClientTest
9 | * @author jinyu(foxinmy@gmail.com)
10 | * @date 2016年7月28日
11 | * @since JDK 1.6
12 | */
13 | public class NettyHttpClientTest extends HttpClientTest {
14 |
15 | @Override
16 | protected HttpClientFactory createHttpFactory() {
17 | return new Netty4HttpClientFactory();
18 | }
19 | }
20 |
--------------------------------------------------------------------------------
/weixin4j-base/src/test/java/com/foxinmy/weixin4j/base/test/http/OkHttp2ClinetTest.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.base.test.http;
2 |
3 | import com.foxinmy.weixin4j.http.factory.HttpClientFactory;
4 | import com.foxinmy.weixin4j.http.support.okhttp.OkHttpClient2Factory;
5 |
6 | /**
7 | * OkHttp for test
8 | *
9 | * @className OkHttpClinetTest
10 | * @author jinyu(foxinmy@gmail.com)
11 | * @date 2016年7月28日
12 | * @since JDK 1.6
13 | */
14 | public class OkHttp2ClinetTest extends HttpClientTest {
15 | @Override
16 | protected HttpClientFactory createHttpFactory() {
17 | return new OkHttpClient2Factory();
18 | }
19 | }
20 |
--------------------------------------------------------------------------------
/weixin4j-base/src/test/java/com/foxinmy/weixin4j/base/test/http/OkHttp3ClinetTest.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.base.test.http;
2 |
3 | import com.foxinmy.weixin4j.http.factory.HttpClientFactory;
4 | import com.foxinmy.weixin4j.http.support.okhttp.OkHttpClient3Factory;
5 |
6 | /**
7 | * OkHttp for test
8 | *
9 | * @className OkHttpClinetTest
10 | * @author jinyu(foxinmy@gmail.com)
11 | * @date 2016年7月28日
12 | * @since JDK 1.6
13 | */
14 | public class OkHttp3ClinetTest extends HttpClientTest {
15 | @Override
16 | protected HttpClientFactory createHttpFactory() {
17 | return new OkHttpClient3Factory();
18 | }
19 | }
20 |
--------------------------------------------------------------------------------
/weixin4j-base/src/test/java/com/foxinmy/weixin4j/base/test/http/SimpleHttpTest.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.base.test.http;
2 |
3 | import com.foxinmy.weixin4j.http.factory.HttpClientFactory;
4 | import com.foxinmy.weixin4j.http.factory.SimpleHttpClientFactory;
5 |
6 | /**
7 | * SimpleClient for test
8 | * @className SimpleHttpTest
9 | * @author jinyu(foxinmy@gmail.com)
10 | * @date 2016年7月28日
11 | * @since JDK 1.6
12 | */
13 | public class SimpleHttpTest extends HttpClientTest {
14 |
15 | @Override
16 | protected HttpClientFactory createHttpFactory() {
17 | return new SimpleHttpClientFactory();
18 | }
19 | }
20 |
--------------------------------------------------------------------------------
/weixin4j-base/src/test/java/com/foxinmy/weixin4j/util/ConstsTest.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.util;
2 |
3 | import static org.junit.Assert.assertEquals;
4 | import static org.junit.Assert.assertFalse;
5 |
6 | import org.junit.Test;
7 |
8 | public class ConstsTest {
9 |
10 | @Test
11 | public void test() {
12 | assertEquals("weixin4j", Consts.WEIXIN4J);
13 | assertFalse(Consts.VERSION.equals("${project.version}"));
14 | }
15 |
16 | }
17 |
--------------------------------------------------------------------------------
/weixin4j-example/.gitignore:
--------------------------------------------------------------------------------
1 | # Mobile Tools for Java (J2ME)
2 | .mtj.tmp/
3 |
4 | # Package Files #
5 | *.jar
6 | *.war
7 | *.ear
8 |
9 | # virtual machine crash logs, see http://www.java.com/en/download/help/error_hotspot.xml
10 | hs_err_pid*
11 |
12 | *~
13 |
14 | # eclipse ignore
15 | *.settings/*
16 | /.project
17 | /.classpath
18 | /.tomcatplugin
19 |
20 | # idea ignore
21 | /.idea
22 | *.iml
23 |
24 | # maven ignore
25 | target/*
26 |
27 | # other ignore
28 | *.log
29 | *.tmp
30 | Thumbs.db
31 | /target/
32 | .DS_Store
33 | bin
34 | /target/
35 | /target/
36 | /target/
37 |
--------------------------------------------------------------------------------
/weixin4j-example/src/main/java/com/foxinmy/weixin4j/example/controller/IndexController.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.example.controller;
2 |
3 | import org.springframework.beans.factory.annotation.Autowired;
4 | import org.springframework.stereotype.Controller;
5 | import org.springframework.web.bind.annotation.RequestMapping;
6 |
7 | import com.foxinmy.weixin4j.mp.WeixinProxy;
8 |
9 | @Controller
10 | @RequestMapping("")
11 | public class IndexController {
12 | @Autowired
13 | private WeixinProxy weixinProxy;
14 |
15 | @RequestMapping
16 | public String index() {
17 | return "index";
18 | }
19 | }
20 |
--------------------------------------------------------------------------------
/weixin4j-example/src/main/java/com/foxinmy/weixin4j/example/server/handler/ChatMessageHandler.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.example.server.handler;
2 |
3 | import java.util.Set;
4 |
5 | import com.foxinmy.weixin4j.handler.WeixinMessageHandler;
6 | import com.foxinmy.weixin4j.qy.chat.WeixinChatMessage;
7 | import com.foxinmy.weixin4j.request.WeixinMessage;
8 | import com.foxinmy.weixin4j.request.WeixinRequest;
9 | import com.foxinmy.weixin4j.response.BlankResponse;
10 | import com.foxinmy.weixin4j.response.WeixinResponse;
11 |
12 | public class ChatMessageHandler implements WeixinMessageHandler {
13 |
14 | @Override
15 | public boolean canHandle(WeixinRequest request, WeixinMessage message, Set nodeNames) {
16 | return nodeNames.contains("PackageId");
17 | }
18 |
19 | @Override
20 | public WeixinResponse doHandle(WeixinRequest request, WeixinMessage message) {
21 | WeixinChatMessage chatMessage = null; // 转换为实体
22 | return BlankResponse.global;
23 | }
24 |
25 | @Override
26 | public int weight() {
27 | return 0;
28 | }
29 | }
30 |
--------------------------------------------------------------------------------
/weixin4j-example/src/main/java/com/foxinmy/weixin4j/example/server/handler/SubscribeMessageHandler.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.example.server.handler;
2 |
3 | import org.springframework.stereotype.Component;
4 |
5 | import com.foxinmy.weixin4j.handler.MessageHandlerAdapter;
6 | import com.foxinmy.weixin4j.mp.event.ScribeEventMessage;
7 | import com.foxinmy.weixin4j.request.WeixinRequest;
8 | import com.foxinmy.weixin4j.response.TextResponse;
9 | import com.foxinmy.weixin4j.response.WeixinResponse;
10 |
11 | /**
12 | * 处理关注消息
13 | *
14 | * @className SubscribeMessageHandler
15 | * @author jinyu(foxinmy@gmail.com)
16 | * @date 2015年12月3日
17 | * @since JDK 1.6
18 | */
19 | @Component
20 | public class SubscribeMessageHandler extends MessageHandlerAdapter {
21 |
22 | @Override
23 | public WeixinResponse doHandle0(ScribeEventMessage message) {
24 | return new TextResponse("欢迎关注~");
25 | }
26 | }
27 |
--------------------------------------------------------------------------------
/weixin4j-example/src/main/java/com/foxinmy/weixin4j/example/server/handler/TextMessageHandler.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.example.server.handler;
2 |
3 | import org.springframework.stereotype.Component;
4 |
5 | import com.foxinmy.weixin4j.handler.MessageHandlerAdapter;
6 | import com.foxinmy.weixin4j.message.TextMessage;
7 | import com.foxinmy.weixin4j.request.WeixinRequest;
8 | import com.foxinmy.weixin4j.response.TextResponse;
9 | import com.foxinmy.weixin4j.response.WeixinResponse;
10 |
11 | /**
12 | * 文本消息处理
13 | *
14 | * @className TextMessageHandler
15 | * @author jinyu(foxinmy@gmail.com)
16 | * @date 2015年11月18日
17 | * @since JDK 1.6
18 | */
19 | @Component
20 | public class TextMessageHandler extends MessageHandlerAdapter {
21 | @Override
22 | public WeixinResponse doHandle0(TextMessage message) {
23 | return new TextResponse("收到了文本消息");
24 | }
25 | }
26 |
--------------------------------------------------------------------------------
/weixin4j-example/src/main/java/com/foxinmy/weixin4j/example/server/handler/VoiceMessageHandler.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.example.server.handler;
2 |
3 | import org.springframework.stereotype.Component;
4 |
5 | import com.foxinmy.weixin4j.handler.MessageHandlerAdapter;
6 | import com.foxinmy.weixin4j.message.VoiceMessage;
7 | import com.foxinmy.weixin4j.request.WeixinRequest;
8 | import com.foxinmy.weixin4j.response.TextResponse;
9 | import com.foxinmy.weixin4j.response.WeixinResponse;
10 |
11 | /**
12 | * 只处理语音消息
13 | *
14 | * @className VoiceMessageHandler
15 | * @author jinyu(foxinmy@gmail.com)
16 | * @date 2015年11月18日
17 | * @since JDK 1.6
18 | */
19 | @Component
20 | public class VoiceMessageHandler extends MessageHandlerAdapter {
21 |
22 | @Override
23 | public WeixinResponse doHandle0(VoiceMessage message) {
24 | /**
25 | * 返回一段文字给用户
26 | */
27 | return new TextResponse("你讲了一句话");
28 | }
29 | }
30 |
--------------------------------------------------------------------------------
/weixin4j-example/src/main/resources/spring-bean.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
8 |
9 |
10 |
11 |
12 |
--------------------------------------------------------------------------------
/weixin4j-example/src/main/resources/spring-weixin4j-server.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
7 |
8 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
--------------------------------------------------------------------------------
/weixin4j-example/src/main/script/assembly.xml:
--------------------------------------------------------------------------------
1 |
2 |
6 | bin
7 |
8 | zip
9 |
10 |
11 |
12 |
13 | io.netty:netty-all
14 | com.foxinmy:weixin4j-server
15 | com.foxinmy:weixin4j-example
16 |
17 | true
18 | /lib
19 |
20 |
21 |
22 |
23 | src/main/script
24 | /
25 |
26 | *.sh
27 | *.bat
28 |
29 |
30 |
31 |
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/WEB-INF/view/index.jsp:
--------------------------------------------------------------------------------
1 | <%@ page language="java" contentType="text/html; charset=UTF-8"
2 | pageEncoding="UTF-8"%>
3 | <%@ include file="/WEB-INF/view/taglibs.jsp"%>
4 |
5 |
6 |
7 |
8 |
10 | weixin4j
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 | 基础说明
19 | - 开始使用
20 |
21 |
22 |
23 |
24 |
开始使用
25 |
weixin4j
26 |
27 |
28 |
29 |
30 |
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/WEB-INF/view/taglibs.jsp:
--------------------------------------------------------------------------------
1 | <%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
2 | <%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt"%>
3 | <%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn"%>
4 |
5 |
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/css/modules/code.css:
--------------------------------------------------------------------------------
1 | /** layui-v1.0.1 经典模块化前端框架@LGPL www.layui.com By 贤心 */
2 | html #layuicss-skincodecss{display:none;position:absolute;width:1989px}.layui-code-h3,.layui-code-view{position:relative;font-size:12px}.layui-code-view{display:block;margin:10px 0;padding:0;border:1px solid #ddd;border-left-width:6px;background-color:#F2F2F2;color:#333;font-family:Courier New}.layui-code-h3{padding:0 10px;height:30px;line-height:30px;border-bottom:1px solid #ddd}.layui-code-h3 a{position:absolute;right:10px;top:0;color:#999}.layui-code-view .layui-code-ol{position:relative;overflow:auto}.layui-code-view .layui-code-ol li{position:relative;margin-left:45px;line-height:20px;padding:0 5px;border-left:1px solid #ddd;list-style-type:decimal-leading-zero;*list-style-type:decimal;background-color:#fff}.layui-code-view pre{margin:0}.layui-code-notepad{border:1px solid #0C0C0C;border-left-color:#3F3F3F;background-color:#0C0C0C;color:#C2BE9E}.layui-code-notepad .layui-code-h3{border-bottom:none}.layui-code-notepad .layui-code-ol li{background-color:#3F3F3F;border-left:none}
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/css/modules/laydate/icon.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/css/modules/laydate/icon.png
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/css/modules/layer/default/icon-ext.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/css/modules/layer/default/icon-ext.png
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/css/modules/layer/default/icon.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/css/modules/layer/default/icon.png
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/css/modules/layer/default/loading-0.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/css/modules/layer/default/loading-0.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/css/modules/layer/default/loading-1.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/css/modules/layer/default/loading-1.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/css/modules/layer/default/loading-2.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/css/modules/layer/default/loading-2.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/font/iconfont.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/font/iconfont.eot
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/font/iconfont.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/font/iconfont.ttf
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/font/iconfont.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/font/iconfont.woff
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/0.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/0.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/1.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/1.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/10.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/10.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/11.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/11.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/12.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/12.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/13.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/13.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/14.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/14.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/15.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/15.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/16.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/16.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/17.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/17.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/18.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/18.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/19.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/19.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/2.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/2.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/20.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/20.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/21.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/21.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/22.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/22.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/23.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/23.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/24.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/24.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/25.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/25.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/26.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/26.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/27.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/27.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/28.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/28.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/29.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/29.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/3.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/3.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/30.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/30.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/31.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/31.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/32.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/32.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/33.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/33.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/34.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/34.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/35.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/35.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/36.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/36.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/37.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/37.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/38.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/38.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/39.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/39.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/4.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/4.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/40.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/40.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/41.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/41.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/42.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/42.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/43.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/43.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/44.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/44.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/45.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/45.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/46.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/46.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/47.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/47.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/48.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/48.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/49.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/49.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/5.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/5.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/50.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/50.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/51.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/51.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/52.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/52.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/53.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/53.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/54.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/54.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/55.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/55.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/56.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/56.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/57.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/57.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/58.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/58.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/59.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/59.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/6.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/6.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/60.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/60.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/61.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/61.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/62.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/62.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/63.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/63.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/64.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/64.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/65.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/65.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/66.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/66.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/67.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/67.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/68.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/68.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/69.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/69.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/7.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/7.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/70.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/70.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/71.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/71.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/8.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/8.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/images/face/9.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/foxinmy/weixin4j/f1dca9c6b8c7306bf6cca0ea7251830e5d67c8aa/weixin4j-example/src/main/webapp/static/layui/images/face/9.gif
--------------------------------------------------------------------------------
/weixin4j-example/src/main/webapp/static/layui/lay/modules/util.js:
--------------------------------------------------------------------------------
1 | /** layui-v1.0.1 经典模块化前端框架 LGPL license By www.layui.com */
2 | ;layui.define("jquery",function(l){"use strict";var o=layui.jquery,i={fixbar:function(l){l=l||{},l.bgcolor=l.bgcolor?"background-color:"+l.bgcolor:"";var i,a,c="layui-fixbar-top",t=[l.bar1===!0?"":l.bar1,l.bar2===!0?"":l.bar2,""],r=o(['',l.bar1?'- '+t[0]+"
":"",l.bar2?'- '+t[1]+"
":"",'- '+t[2]+"
","
"].join("")),e=r.find("."+c),s=function(){var i=o(document).scrollTop();i>=(l.showHeight||200)?a||(e.show(),a=1):a&&(e.hide(),a=0)};o(".layui-fixbar")[0]||("object"==typeof l.css&&r.css(l.css),o("body").append(r),s(),r.find("li").on("click",function(){var i=o(this),a=i.attr("lay-type");"top"===a&&o("html,body").animate({scrollTop:0},200),l.click&&l.click.call(this,a)}),o(document).on("scroll",function(){i&&clearTimeout(i),i=setTimeout(function(){s()},100)}))}};l("util",i)});
--------------------------------------------------------------------------------
/weixin4j-mp/.gitignore:
--------------------------------------------------------------------------------
1 | # Mobile Tools for Java (J2ME)
2 | .mtj.tmp/
3 |
4 | # Package Files #
5 | *.jar
6 | *.war
7 | *.ear
8 |
9 | # virtual machine crash logs, see http://www.java.com/en/download/help/error_hotspot.xml
10 | hs_err_pid*
11 |
12 | *~
13 |
14 | # eclipse ignore
15 | *.settings/*
16 | /.project
17 | /.classpath
18 | /.tomcatplugin
19 |
20 | # idea ignore
21 | /.idea
22 | *.iml
23 |
24 | # maven ignore
25 | target/*
26 |
27 | # other ignore
28 | *.log
29 | *.tmp
30 | Thumbs.db
31 | /target/
32 | .DS_Store
33 | /target/
34 | /target/
35 |
--------------------------------------------------------------------------------
/weixin4j-mp/README.md:
--------------------------------------------------------------------------------
1 | weixin4j-mp
2 | ===========
3 |
4 | [微信公众平台](http://mp.weixin.qq.com/wiki)开发工具包
5 | ----------------------------------------------------
6 |
7 | 功能列表
8 | -------
9 |
10 | * CustomApi `多客服API`
11 |
12 | * DataApi `数据统计API`
13 |
14 | * GroupApi `分组管理API`
15 |
16 | * HelperApi `辅助API`
17 |
18 | * MassApi `群发消息API`
19 |
20 | * MediaApi `上传/下载媒体文件API`
21 |
22 | * MenuApi `底部菜单API`
23 |
24 | * NotifyApi `客服消息API`
25 |
26 | * OauthApi `oauth授权API`
27 |
28 | * Pay2Api `V2支付API`
29 |
30 | * QrApi `二维码API`
31 |
32 | * TmplApi `模板消息API`
33 |
34 | * UserApi `用户管理API`
35 |
36 | * TagApi `用户标签管理API`
37 |
38 | * ComponentApi `第三方组件API`
39 |
40 | * CardApi `卡券API`
41 |
42 | * CommentApi `评论API`
43 |
44 | [如何使用](https://github.com/foxinmy/weixin4j/wiki)
45 | ---------
46 |
47 | [更新LOG](./CHANGE.md)
48 | ----------------------
--------------------------------------------------------------------------------
/weixin4j-mp/src/main/java/com/foxinmy/weixin4j/mp/api/MpApi.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.mp.api;
2 |
3 | import java.util.ResourceBundle;
4 |
5 | import com.foxinmy.weixin4j.api.BaseApi;
6 |
7 | /**
8 | * 微信公众平台API
9 | *
10 | * @className MpApi
11 | * @author jinyu(foxinmy@gmail.com)
12 | * @date 2014年9月26日
13 | * @since JDK 1.6
14 | * @see com.foxinmy.weixin4j.api.BaseApi
15 | * @see api文档
16 | */
17 | public class MpApi extends BaseApi {
18 |
19 | private final static ResourceBundle WEIXIN_BUNDLE;
20 |
21 | static {
22 | WEIXIN_BUNDLE = ResourceBundle
23 | .getBundle("com/foxinmy/weixin4j/mp/api/weixin");
24 | }
25 |
26 | @Override
27 | protected ResourceBundle weixinBundle() {
28 | return WEIXIN_BUNDLE;
29 | }
30 | }
31 |
--------------------------------------------------------------------------------
/weixin4j-mp/src/main/java/com/foxinmy/weixin4j/mp/api/README.md:
--------------------------------------------------------------------------------
1 | * CustomApi `多客服API`
2 |
3 | * DataApi `数据统计API`
4 |
5 | * GroupApi `分组管理API`
6 |
7 | * HelperApi `辅助API`
8 |
9 | * MassApi `群发消息API`
10 |
11 | * MediaApi `上传/下载媒体文件API`
12 |
13 | * MenuApi `底部菜单API`
14 |
15 | * NotifyApi `客服消息API`
16 |
17 | * OauthApi `oauth授权API`
18 |
19 | * Pay2Api `原V2支付API`
20 |
21 | * QrApi `二维码API`
22 |
23 | * TmplApi `模板消息API`
24 |
25 | * UserApi `用户管理API`
26 |
27 | * TagApi `用户标签管理API`
28 |
29 | * ComponentApi `第三方组件API`
30 |
31 | * CardApi `卡券API`
32 |
33 | * CommentApi `评论API`
--------------------------------------------------------------------------------
/weixin4j-mp/src/main/java/com/foxinmy/weixin4j/mp/model/MenuSetting.java:
--------------------------------------------------------------------------------
1 | package com.foxinmy.weixin4j.mp.model;
2 |
3 | import java.io.Serializable;
4 | import java.util.List;
5 |
6 | import com.foxinmy.weixin4j.model.Button;
7 |
8 | /**
9 | * 自定义菜单配置
10 | *
11 | * @className MenuSetting
12 | * @author jinyu(foxinmy@gmail.com)
13 | * @date 2015年4月14日
14 | * @since JDK 1.6
15 | * @see
16 | */
17 | public class MenuSetting implements Serializable {
18 |
19 | private static final long serialVersionUID = 2461505572495855830L;
20 |
21 | /**
22 | * 菜单是否开启
23 | */
24 | private boolean isMenuOpen;
25 | /**
26 | * 菜单列表
27 | */
28 | private List