cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From serg...@apache.org
Subject cxf git commit: Updating WADLGenerator to block the recursion for XMLGregorianCalendar
Date Mon, 30 May 2016 09:57:43 GMT
Repository: cxf
Updated Branches:
  refs/heads/3.0.x-fixes 9a6895f45 -> c528de6c7


Updating WADLGenerator to block the recursion for XMLGregorianCalendar


Project: http://git-wip-us.apache.org/repos/asf/cxf/repo
Commit: http://git-wip-us.apache.org/repos/asf/cxf/commit/c528de6c
Tree: http://git-wip-us.apache.org/repos/asf/cxf/tree/c528de6c
Diff: http://git-wip-us.apache.org/repos/asf/cxf/diff/c528de6c

Branch: refs/heads/3.0.x-fixes
Commit: c528de6c70479c9b872fd754d66a48897cdd5bf6
Parents: 9a6895f
Author: Sergey Beryozkin <sberyozkin@gmail.com>
Authored: Mon May 30 10:53:21 2016 +0100
Committer: Sergey Beryozkin <sberyozkin@gmail.com>
Committed: Mon May 30 10:57:26 2016 +0100

----------------------------------------------------------------------
 .../java/org/apache/cxf/jaxrs/model/wadl/WadlGenerator.java     | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cxf/blob/c528de6c/rt/rs/description/src/main/java/org/apache/cxf/jaxrs/model/wadl/WadlGenerator.java
----------------------------------------------------------------------
diff --git a/rt/rs/description/src/main/java/org/apache/cxf/jaxrs/model/wadl/WadlGenerator.java
b/rt/rs/description/src/main/java/org/apache/cxf/jaxrs/model/wadl/WadlGenerator.java
index b8f1716..1a04650 100644
--- a/rt/rs/description/src/main/java/org/apache/cxf/jaxrs/model/wadl/WadlGenerator.java
+++ b/rt/rs/description/src/main/java/org/apache/cxf/jaxrs/model/wadl/WadlGenerator.java
@@ -69,6 +69,7 @@ import javax.xml.bind.JAXBContext;
 import javax.xml.bind.annotation.XmlRootElement;
 import javax.xml.bind.annotation.XmlSeeAlso;
 import javax.xml.bind.annotation.XmlType;
+import javax.xml.datatype.XMLGregorianCalendar;
 import javax.xml.namespace.QName;
 import javax.xml.parsers.ParserConfigurationException;
 import javax.xml.stream.XMLStreamException;
@@ -875,7 +876,9 @@ public class WadlGenerator implements ContainerRequestFilter {
             }
             Class<?> paramCls = entry.getValue();
             boolean isPrimitive = InjectionUtils.isPrimitive(paramCls) || paramCls.isEnum();
-            if (isPrimitive || Date.class.isAssignableFrom(paramCls) 
+            if (isPrimitive 
+                || Date.class.isAssignableFrom(paramCls)
+                || XMLGregorianCalendar.class.isAssignableFrom(paramCls)
                 || InjectionUtils.isSupportedCollectionOrArray(paramCls)) {
                 doWriteParam(ori, sb, entry.getKey(), paramCls, paramCls, name, new Annotation[]
{}, isJson);
             } else if (!parentBeanClasses.contains(paramCls)) {


Mime
View raw message