This is an automated email from the ASF dual-hosted git repository. dkulp pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/cxf.git
The following commit(s) were added to refs/heads/master by this push: new 8f6a234 CXF-7695 Revert some changes from commit bcb6385a095dcaaf8390ecfc33e9e22b9149daad that cause a problem when generating ws client jars with jaxws bindings 8f6a234 is described below commit 8f6a234b28503eb1b820d4e79a9b18e6f4beb2f1 Author: Reto Weiss <reto.we...@ivyteam.ch> AuthorDate: Tue Apr 3 15:55:53 2018 +0200 CXF-7695 Revert some changes from commit bcb6385a095dcaaf8390ecfc33e9e22b9149daad that cause a problem when generating ws client jars with jaxws bindings --- .../customization/JAXWSBindingSerializer.java | 44 ++++++++++++++++++++++ .../jaxws/wsdl11/JAXWSDefinitionBuilder.java | 2 + 2 files changed, 46 insertions(+) diff --git a/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/customization/JAXWSBindingSerializer.java b/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/customization/JAXWSBindingSerializer.java new file mode 100644 index 0000000..af49881 --- /dev/null +++ b/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/customization/JAXWSBindingSerializer.java @@ -0,0 +1,44 @@ +/** + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.cxf.tools.wsdlto.frontend.jaxws.customization; + +import java.io.*; + +import javax.wsdl.Definition; +import javax.wsdl.WSDLException; +import javax.wsdl.extensions.ExtensibilityElement; +import javax.wsdl.extensions.ExtensionRegistry; +import javax.wsdl.extensions.ExtensionSerializer; +import javax.xml.namespace.QName; + +public class JAXWSBindingSerializer implements ExtensionSerializer, Serializable { + public static final long serialVersionUID = 1; + + public void marshall(@SuppressWarnings("rawtypes") Class parentType, + QName elementType, + ExtensibilityElement extension, + PrintWriter pw, + Definition def, + ExtensionRegistry extReg) + throws WSDLException { + // This class is needed to generate the WSDL file included in the client jar. + // It simply ignores the JAXWS Binding when generating the WSDL file. + } +} diff --git a/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/wsdl11/JAXWSDefinitionBuilder.java b/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/wsdl11/JAXWSDefinitionBuilder.java index 77e5cb8..9bcba86 100644 --- a/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/wsdl11/JAXWSDefinitionBuilder.java +++ b/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/wsdl11/JAXWSDefinitionBuilder.java @@ -55,6 +55,7 @@ import org.apache.cxf.tools.wsdlto.core.WSDLDefinitionBuilder; import org.apache.cxf.tools.wsdlto.frontend.jaxws.customization.CustomizationParser; import org.apache.cxf.tools.wsdlto.frontend.jaxws.customization.JAXWSBinding; import org.apache.cxf.tools.wsdlto.frontend.jaxws.customization.JAXWSBindingDeserializer; +import org.apache.cxf.tools.wsdlto.frontend.jaxws.customization.JAXWSBindingSerializer; import org.apache.cxf.wsdl.WSDLManager; public class JAXWSDefinitionBuilder extends AbstractWSDLBuilder { @@ -99,6 +100,7 @@ public class JAXWSDefinitionBuilder extends AbstractWSDLBuilder { } private void registerJAXWSBinding(ExtensionRegistry registry, Class<?> clz) { + registry.registerSerializer(clz, ToolConstants.JAXWS_BINDINGS, new JAXWSBindingSerializer()); registry.registerDeserializer(clz, ToolConstants.JAXWS_BINDINGS, new JAXWSBindingDeserializer()); registry.mapExtensionTypes(clz, ToolConstants.JAXWS_BINDINGS, JAXWSBinding.class); } -- To stop receiving notification emails like this one, please contact dk...@apache.org.