package com.nko.bean; import java.util.List; /** * 微信xml消息中的参数列表 * @author ZZK * */ public class Parameter { private String fromUserName; private String toUserName; private String msgType; private String time; private String content; private String url; private String picUrl; private String title; private String description; private String funcFlag; private String event; private String eventKey; private List<Parameter> item; private String category; // 标识信息是发送的还是接收的 public List<Parameter> getItem() { return item; } public void setItem(List<Parameter> item) { this.item = item; } public String getFromUserName() { return fromUserName; } public void setFromUserName(String fromUserName) { this.fromUserName = fromUserName; } public String getToUserName() { return toUserName; } public void setToUserName(String toUserName) { this.toUserName = toUserName; } public String getMsgType() { return msgType; } public void setMsgType(String type) { this.msgType = type; } public String getTime() { return time; } public void setTime(String time) { this.time = time; } public String getContent() { return content; } public void setContent(String content) { this.content = content; } public String getUrl() { if(this.msgType.equals("link")) return this.content.substring( this.content.indexOf("href=\"") + ("href=\"").length(), this.content.indexOf("\">")); else return url; } public void setUrl(String url) { this.url = url; } public String getPicUrl() { return picUrl; } public void setPicUrl(String picUrl) { this.picUrl = picUrl; } public String getTitle() { return title; } public void setTitle(String title) { this.title = title; } public String getDescription() { return description; } public void setDescription(String description) { this.description = description; } public String getFuncFlag() { return funcFlag; } public void setFuncFlag(String funcFlag) { this.funcFlag = funcFlag; } public String getEvent() { return event; } public void setEvent(String event) { this.event = event; } public String getEventKey() { return eventKey; } public void setEventKey(String eventKey) { this.eventKey = eventKey; } public String getCategory() { return category; } public void setCategory(String category) { this.category = category; } public static void main(String[] args) { // List<Parameter> list = new ArrayList<Parameter>(); // Parameter param = new Parameter(); // param.setToUserName("toUser"); // param.setFromUserName("gh_584fc179bafc"); // param.setMsgType("text"); // param.setContent("这是一条文本消息"); // param.setCategory("发送"); // list.add(param); // param.setToUserName("toUser"); // param.setFromUserName("gh_584fc179bafc"); // param.setMsgType("text"); // param.setContent("这是又一条文本消息"); // param.setCategory("发送"); // list.add(param); // //// try { //// json = JsonFactory.toJson(list); //// } catch (Exception e) { //// e.printStackTrace(); //// } //// System.out.println(json); // // JSONArray json = JSONArray.fromObject(param); // System.out.println(json); } }

liu2022 LV14
2022年7月31日
dongzhan LV11
2021年12月16日
Tayirjan LV10
2021年12月1日
tcloud LV1
2021年10月30日
陈志远 LV1
2021年9月8日
seiseisizuka LV1
2021年8月5日
yuzhang LV2
2021年2月1日
wfqdxdx LV6
2020年5月21日
MrZive LV6
2020年5月6日
linghongjun5002 LV10
2020年4月15日

dengjunjun LV15
1月11日
uni-code_0123 LV1
2022年11月3日
babyFF9 LV8
2022年9月26日
微信网友_6139616720490496 LV1
2022年9月19日
xiex909 LV27
2022年8月19日
liu2022 LV14
2022年7月31日
豆子小兔子 LV9
2022年7月25日
pengleilei LV3
2022年4月14日
nbzhou2013 LV13
2022年4月4日
HANCW LV5
2022年3月14日