public abstract class AbstractXmlNodeConvert extends AbstractWeiXinConvert
Modifier and Type | Field and Description |
---|---|
protected static Logger |
LOGGER |
protected com.thoughtworks.xstream.XStream |
xstream |
clazz
Constructor and Description |
---|
AbstractXmlNodeConvert(Class<?> clazz) |
Modifier and Type | Method and Description |
---|---|
protected abstract boolean |
checkMatch(XmlNode input,
WeiXinContext context)
根据报文内容进行判断
|
protected boolean |
contains(XmlNode input,
String nodename) |
<OUTPUT,INPUT> |
convert(INPUT input,
WeiXinContext context)
转换消息(微信报文会出现不同类型报文字段一致的情况,需要根据上下文判断)
|
protected <OUTPUT> OUTPUT |
convertXmlNode(XmlNode input,
WeiXinContext context)
转换XmlNode为业务对象
|
protected String |
get(XmlNode input,
String nodename) |
protected String |
getEncrypt(XmlNode input) |
protected String |
getEvent(XmlNode input) |
protected String |
getMsgType(XmlNode input) |
protected void |
init()
初始化方法
|
<INPUT> boolean |
isMatch(INPUT input,
WeiXinContext context)
判断转换接口能否处理输入信息(微信报文会出现不同类型报文字段一致的情况,需要根据上下文判断)
|
checkResultType, compareTo, getCalssType, getPriority, setPriority
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getWeiXinConvertMode
protected static final Logger LOGGER
protected com.thoughtworks.xstream.XStream xstream
public AbstractXmlNodeConvert(Class<?> clazz)
public <INPUT> boolean isMatch(INPUT input, WeiXinContext context)
WeiXinConvert
public <OUTPUT,INPUT> OUTPUT convert(INPUT input, WeiXinContext context)
WeiXinConvert
protected abstract boolean checkMatch(XmlNode input, WeiXinContext context)
input
- context
- protected <OUTPUT> OUTPUT convertXmlNode(XmlNode input, WeiXinContext context)
OUTPUT
- input
- context
- protected void init()
Copyright © 2006–2018 TinyGroup. All rights reserved.