private XmlJavaTypeAdapter getApplicableAdapter(T type) {
XmlJavaTypeAdapter jta = seed.readAnnotation(XmlJavaTypeAdapter.class);
if (jta != null && isApplicable(jta, type))
return jta;
// check the applicable adapters on the package
XmlJavaTypeAdapters jtas = reader().getPackageAnnotation(XmlJavaTypeAdapters.class, parent.clazz, seed);
if (jtas != null) {
for (XmlJavaTypeAdapter xjta : jtas.value()) {
if (isApplicable(xjta, type))
return xjta;
}
}
jta = reader().getPackageAnnotation(XmlJavaTypeAdapter.class, parent.clazz, seed);
if (isApplicable(jta, type))
return jta;
if (type instanceof Type) {
jta = JefAdapters.get((Type)type);
if (jta != null && isApplicable(jta, type)) {
return jta;
}
}
// then on the target class
C refType = nav().asDecl(type);
if (refType != null) {
jta = reader().getClassAnnotation(XmlJavaTypeAdapter.class, refType, seed);
if (jta != null && isApplicable(jta, type)) // the one on the type
// always apply.
return jta;
}
return null;
}
PropertyInfoImpl.java 文件源码
java
阅读 26
收藏 0
点赞 0
评论 0
项目:cxf-plus
作者:
评论列表
文章目录