本文整理了Java中me.chanjar.weixin.common.util.xml.XStreamInitializer
类的一些代码示例,展示了XStreamInitializer
类的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。XStreamInitializer
类的具体详情如下:
包路径:me.chanjar.weixin.common.util.xml.XStreamInitializer
类名称:XStreamInitializer
暂无
代码示例来源:origin: chanjarster/weixin-java-tools
@Override
public WxMpPayCallback getJSSDKCallbackData(String xmlData) {
try {
XStream xstream = XStreamInitializer.getInstance();
xstream.alias("xml", WxMpPayCallback.class);
WxMpPayCallback wxMpCallback = (WxMpPayCallback) xstream.fromXML(xmlData);
return wxMpCallback;
} catch (Exception e){
e.printStackTrace();
}
return new WxMpPayCallback();
}
代码示例来源:origin: chanjarster/weixin-java-tools
private static XStream config_WxMpXmlOutImageMessage() {
XStream xstream = XStreamInitializer.getInstance();
xstream.processAnnotations(WxMpXmlOutMessage.class);
xstream.processAnnotations(WxMpXmlOutImageMessage.class);
return xstream;
}
代码示例来源:origin: chanjarster/weixin-java-tools
private static XStream config_WxMpXmlOutTextMessage() {
XStream xstream = XStreamInitializer.getInstance();
xstream.processAnnotations(WxMpXmlOutMessage.class);
xstream.processAnnotations(WxMpXmlOutTextMessage.class);
return xstream;
}
代码示例来源:origin: chanjarster/weixin-java-tools
private static XStream config_WxCpXmlOutImageMessage() {
XStream xstream = XStreamInitializer.getInstance();
xstream.processAnnotations(WxCpXmlOutMessage.class);
xstream.processAnnotations(WxCpXmlOutImageMessage.class);
return xstream;
}
代码示例来源:origin: chanjarster/weixin-java-tools
private static XStream config_WxCpXmlOutTextMessage() {
XStream xstream = XStreamInitializer.getInstance();
xstream.processAnnotations(WxCpXmlOutMessage.class);
xstream.processAnnotations(WxCpXmlOutTextMessage.class);
return xstream;
}
代码示例来源:origin: chanjarster/weixin-java-tools
private static XStream config_WxCpXmlOutVoiceMessage() {
XStream xstream = XStreamInitializer.getInstance();
xstream.processAnnotations(WxCpXmlOutMessage.class);
xstream.processAnnotations(WxCpXmlOutVoiceMessage.class);
return xstream;
}
代码示例来源:origin: chanjarster/weixin-java-tools
private static XStream config_WxMpXmlOutVoiceMessage() {
XStream xstream = XStreamInitializer.getInstance();
xstream.processAnnotations(WxMpXmlOutMessage.class);
xstream.processAnnotations(WxMpXmlOutVoiceMessage.class);
return xstream;
}
代码示例来源:origin: chanjarster/weixin-java-tools
CloseableHttpResponse response = httpClient.execute(httpPost);
String responseContent = Utf8ResponseHandler.INSTANCE.handleResponse(response);
XStream xstream = XStreamInitializer.getInstance();
xstream.alias("xml", WxMpPayResult.class);
WxMpPayResult wxMpPayResult = (WxMpPayResult) xstream.fromXML(responseContent);
代码示例来源:origin: chanjarster/weixin-java-tools
private static XStream config_WxMpXmlOutNewsMessage() {
XStream xstream = XStreamInitializer.getInstance();
xstream.processAnnotations(WxMpXmlOutMessage.class);
xstream.processAnnotations(WxMpXmlOutNewsMessage.class);
xstream.processAnnotations(WxMpXmlOutNewsMessage.Item.class);
return xstream;
}
代码示例来源:origin: chanjarster/weixin-java-tools
private static XStream config_WxMpXmlOutVideoMessage() {
XStream xstream = XStreamInitializer.getInstance();
xstream.processAnnotations(WxMpXmlOutMessage.class);
xstream.processAnnotations(WxMpXmlOutVideoMessage.class);
xstream.processAnnotations(WxMpXmlOutVideoMessage.Video.class);
return xstream;
}
代码示例来源:origin: chanjarster/weixin-java-tools
CloseableHttpResponse response = getHttpclient().execute(httpPost);
String responseContent = Utf8ResponseHandler.INSTANCE.handleResponse(response);
XStream xstream = XStreamInitializer.getInstance();
xstream.alias("xml", WxMpPrepayIdResult.class);
WxMpPrepayIdResult wxMpPrepayIdResult = (WxMpPrepayIdResult) xstream.fromXML(responseContent);
代码示例来源:origin: chanjarster/weixin-java-tools
private static XStream config_WxCpXmlOutNewsMessage() {
XStream xstream = XStreamInitializer.getInstance();
xstream.processAnnotations(WxCpXmlOutMessage.class);
xstream.processAnnotations(WxCpXmlOutNewsMessage.class);
xstream.processAnnotations(WxCpXmlOutNewsMessage.Item.class);
return xstream;
}
代码示例来源:origin: chanjarster/weixin-java-tools
private static XStream config_WxMpXmlOutMusicMessage() {
XStream xstream = XStreamInitializer.getInstance();
xstream.processAnnotations(WxMpXmlOutMessage.class);
xstream.processAnnotations(WxMpXmlOutMusicMessage.class);
xstream.processAnnotations(WxMpXmlOutMusicMessage.Music.class);
return xstream;
}
代码示例来源:origin: chanjarster/weixin-java-tools
private static XStream config_WxCpXmlOutVideoMessage() {
XStream xstream = XStreamInitializer.getInstance();
xstream.processAnnotations(WxCpXmlOutMessage.class);
xstream.processAnnotations(WxCpXmlOutVideoMessage.class);
xstream.processAnnotations(WxCpXmlOutVideoMessage.Video.class);
return xstream;
}
代码示例来源:origin: chanjarster/weixin-java-tools
private static XStream config_WxMpXmlOutTransferCustomerServiceMessage() {
XStream xstream = XStreamInitializer.getInstance();
xstream.processAnnotations(WxMpXmlOutMessage.class);
xstream.processAnnotations(WxMpXmlOutTransferCustomerServiceMessage.class);
xstream.processAnnotations(WxMpXmlOutTransferCustomerServiceMessage.TransInfo.class);
return xstream;
}
代码示例来源:origin: chanjarster/weixin-java-tools
CloseableHttpResponse response = getHttpclient().execute(httpPost);
String responseContent = Utf8ResponseHandler.INSTANCE.handleResponse(response);
XStream xstream = XStreamInitializer.getInstance();
xstream.processAnnotations(WxRedpackResult.class);
WxRedpackResult wxMpRedpackResult = (WxRedpackResult) xstream.fromXML(responseContent);
代码示例来源:origin: chanjarster/weixin-java-tools
private static XStream config_WxCpXmlMessage() {
XStream xstream = XStreamInitializer.getInstance();
xstream.processAnnotations(WxCpXmlMessage.class);
xstream.processAnnotations(WxCpXmlMessage.ScanCodeInfo.class);
xstream.processAnnotations(WxCpXmlMessage.SendPicsInfo.class);
xstream.processAnnotations(WxCpXmlMessage.SendPicsInfo.Item.class);
xstream.processAnnotations(WxCpXmlMessage.SendLocationInfo.class);
return xstream;
}
代码示例来源:origin: chanjarster/weixin-java-tools
private static XStream config_WxMpXmlMessage() {
XStream xstream = XStreamInitializer.getInstance();
xstream.processAnnotations(WxMpXmlMessage.class);
xstream.processAnnotations(WxMpXmlMessage.ScanCodeInfo.class);
xstream.processAnnotations(WxMpXmlMessage.SendPicsInfo.class);
xstream.processAnnotations(WxMpXmlMessage.SendPicsInfo.Item.class);
xstream.processAnnotations(WxMpXmlMessage.SendLocationInfo.class);
xstream.aliasField("MsgID", WxMpXmlMessage.class, "msgId");
return xstream;
}
代码示例来源:origin: me.chanjar/weixin-java-mp
@Override
public WxMpPayCallback getJSSDKCallbackData(String xmlData) {
try {
XStream xstream = XStreamInitializer.getInstance();
xstream.alias("xml", WxMpPayCallback.class);
WxMpPayCallback wxMpCallback = (WxMpPayCallback) xstream.fromXML(xmlData);
return wxMpCallback;
} catch (Exception e){
e.printStackTrace();
}
return new WxMpPayCallback();
}
代码示例来源:origin: com.github.binarywang/weixin-java-pay
/**
* 从xml字符串构造ReqInfo对象.
*
* @param xmlString xml字符串
* @return ReqInfo对象
*/
public static ReqInfo fromXML(String xmlString) {
XStream xstream = XStreamInitializer.getInstance();
xstream.processAnnotations(ReqInfo.class);
return (ReqInfo) xstream.fromXML(xmlString);
}
}
内容来源于网络,如有侵权,请联系作者删除!