cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dk...@apache.org
Subject svn commit: r551723 - in /incubator/cxf/trunk: common/common/src/main/java/org/apache/cxf/resource/ rt/bindings/http/src/test/java/org/apache/cxf/binding/http/bare/ rt/databinding/aegis/src/main/java/org/apache/cxf/aegis/type/basic/ rt/frontend/jaxws/s...
Date Thu, 28 Jun 2007 22:24:29 GMT
Author: dkulp
Date: Thu Jun 28 15:24:27 2007
New Revision: 551723

URL: http://svn.apache.org/viewvc?view=rev&rev=551723
Log:
Fix charset not being added to HTTP responses
Remove reflection stuff on message pathway in SwAOutInterceptor
Fix use of Class<?> instead of just Class in tooling
Remove use of deprecated File.toUrl() call

Modified:
    incubator/cxf/trunk/common/common/src/main/java/org/apache/cxf/resource/URIResolver.java
    incubator/cxf/trunk/rt/bindings/http/src/test/java/org/apache/cxf/binding/http/bare/BareServiceTest.java
    incubator/cxf/trunk/rt/databinding/aegis/src/main/java/org/apache/cxf/aegis/type/basic/BeanType.java
    incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/interceptors/SwAOutInterceptor.java
    incubator/cxf/trunk/rt/transports/http/src/main/java/org/apache/cxf/transport/http/AbstractHTTPDestination.java
    incubator/cxf/trunk/rt/transports/http/src/main/java/org/apache/cxf/transport/http/HTTPConduit.java
    incubator/cxf/trunk/rt/transports/http/src/main/java/org/apache/cxf/transport/servlet/ServletDestination.java
    incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jaxws/ClientServerGreeterNoWsdlTest.java
    incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jaxws/ClientServerTest.java
    incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jaxws/ClientServerXMLTest.java
    incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/soap12/Soap12ClientServerTest.java
    incubator/cxf/trunk/tools/common/src/main/java/org/apache/cxf/tools/common/toolspec/ToolRunner.java
    incubator/cxf/trunk/tools/common/src/main/java/org/apache/cxf/tools/util/URIParserUtil.java
    incubator/cxf/trunk/tools/common/src/test/java/org/apache/cxf/tools/common/toolspec/parser/CommandLineParserTest.java
    incubator/cxf/trunk/tools/javato/test/src/test/java/org/apache/cxf/tools/java2wsdl/processor/internal/jaxws/WrapperTest.java
    incubator/cxf/trunk/tools/javato/test/src/test/java/org/apache/cxf/tools/java2wsdl/processor/internal/jaxws/WrapperUtilTest.java
    incubator/cxf/trunk/tools/validator/src/main/java/org/apache/cxf/tools/validator/internal/SchemaValidator.java
    incubator/cxf/trunk/tools/validator/src/main/java/org/apache/cxf/tools/validator/internal/ValidatorUtil.java
    incubator/cxf/trunk/tools/validator/src/main/java/org/apache/cxf/tools/validator/internal/WSDL11Validator.java
    incubator/cxf/trunk/tools/wsdlto/core/src/main/java/org/apache/cxf/tools/wsdlto/WSDLToJava.java
    incubator/cxf/trunk/tools/wsdlto/core/src/main/java/org/apache/cxf/tools/wsdlto/core/FrontEndProfile.java
    incubator/cxf/trunk/tools/wsdlto/core/src/main/java/org/apache/cxf/tools/wsdlto/core/Messages.properties
    incubator/cxf/trunk/tools/wsdlto/core/src/main/java/org/apache/cxf/tools/wsdlto/core/PluginLoader.java
    incubator/cxf/trunk/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/processor/internal/ProcessorUtil.java
    incubator/cxf/trunk/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenTest.java

Modified: incubator/cxf/trunk/common/common/src/main/java/org/apache/cxf/resource/URIResolver.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/common/common/src/main/java/org/apache/cxf/resource/URIResolver.java?view=diff&rev=551723&r1=551722&r2=551723
==============================================================================
--- incubator/cxf/trunk/common/common/src/main/java/org/apache/cxf/resource/URIResolver.java (original)
+++ incubator/cxf/trunk/common/common/src/main/java/org/apache/cxf/resource/URIResolver.java Thu Jun 28 15:24:27 2007
@@ -187,7 +187,7 @@
             } catch (FileNotFoundException e) {
                 throw new RuntimeException("File was deleted! " + uriStr, e);
             }
-            url = file.toURL();
+            url = file.toURI().toURL();
         } else if (is == null) {
             tryClasspath(uriStr);
         }

Modified: incubator/cxf/trunk/rt/bindings/http/src/test/java/org/apache/cxf/binding/http/bare/BareServiceTest.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/bindings/http/src/test/java/org/apache/cxf/binding/http/bare/BareServiceTest.java?view=diff&rev=551723&r1=551722&r2=551723
==============================================================================
--- incubator/cxf/trunk/rt/bindings/http/src/test/java/org/apache/cxf/binding/http/bare/BareServiceTest.java (original)
+++ incubator/cxf/trunk/rt/bindings/http/src/test/java/org/apache/cxf/binding/http/bare/BareServiceTest.java Thu Jun 28 15:24:27 2007
@@ -172,7 +172,7 @@
         HttpURLConnection c = (HttpURLConnection)url.openConnection();
         c.setRequestMethod("GET");
         
-        assertEquals("text/xml", c.getContentType());
+        assertEquals("text/xml; charset=utf-8", c.getContentType());
         
         Document doc = DOMUtils.readXml(c.getErrorStream());
         assertValid("//*[text()='You can not map a URI parameter to a "
@@ -201,7 +201,7 @@
         HttpURLConnection c = (HttpURLConnection)url.openConnection();
         c.setRequestMethod("GET");
         
-        assertEquals("text/xml", c.getContentType());
+        assertEquals("text/xml; charset=utf-8", c.getContentType());
         
         Document doc = DOMUtils.readXml(c.getInputStream());
         addNamespace("b", "http://bare.http.binding.cxf.apache.org/");

Modified: incubator/cxf/trunk/rt/databinding/aegis/src/main/java/org/apache/cxf/aegis/type/basic/BeanType.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/databinding/aegis/src/main/java/org/apache/cxf/aegis/type/basic/BeanType.java?view=diff&rev=551723&r1=551722&r2=551723
==============================================================================
--- incubator/cxf/trunk/rt/databinding/aegis/src/main/java/org/apache/cxf/aegis/type/basic/BeanType.java (original)
+++ incubator/cxf/trunk/rt/databinding/aegis/src/main/java/org/apache/cxf/aegis/type/basic/BeanType.java Thu Jun 28 15:24:27 2007
@@ -222,7 +222,7 @@
      * This is a hack to get the write method from the implementation class for
      * an interface.
      */
-    private Method getWriteMethodFromImplClass(Class impl, PropertyDescriptor pd) throws Exception {
+    private Method getWriteMethodFromImplClass(Class<?> impl, PropertyDescriptor pd) throws Exception {
         String name = pd.getName();
         name = "set" + name.substring(0, 1).toUpperCase() + name.substring(1);
 

Modified: incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/interceptors/SwAOutInterceptor.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/interceptors/SwAOutInterceptor.java?view=diff&rev=551723&r1=551722&r2=551723
==============================================================================
--- incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/interceptors/SwAOutInterceptor.java (original)
+++ incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/interceptors/SwAOutInterceptor.java Thu Jun 28 15:24:27 2007
@@ -31,7 +31,6 @@
 import java.util.Iterator;
 import java.util.List;
 import java.util.UUID;
-import java.util.logging.Level;
 import java.util.logging.Logger;
 
 import javax.activation.DataHandler;
@@ -73,6 +72,18 @@
 
 public class SwAOutInterceptor extends AbstractSoapInterceptor {
     private static final Logger LOG = LogUtils.getL7dLogger(SwAOutInterceptor.class);
+    private static final boolean HAS_SWA_REF_METHOD;
+    static {
+        Class<?> cls = JAXBContextImpl.class;
+        Method m = null;
+        try {
+            m = cls.getMethod("hasSwaRef", new Class[0]);
+        } catch (Exception e) {
+            //ignore
+        }
+        HAS_SWA_REF_METHOD = m != null;
+    }
+    
     
     AttachmentOutInterceptor attachOut = new AttachmentOutInterceptor();
     
@@ -193,20 +204,9 @@
     }
     private boolean hasSwaRef(JAXBDataBinding db) {
         JAXBContext context = db.getContext();
-        if (context instanceof JAXBContextImpl) {
-            JAXBContextImpl riCtx = (JAXBContextImpl) context;
-            
-            try {
-                // We're using reflection here because this won't work on
-                // JAXB < 2.0.5 and Java 6 ships with 2.0.2.  This means
-                // SwA won't work correctly unless you're using at least 
-                // JAXB 2.0.5.
-                Method m = riCtx.getClass().getMethod("hasSwaRef", new Class[0]);
-                
-                return (Boolean) m.invoke(riCtx, new Object[0]);
-            } catch (Exception e) {
-                LOG.log(Level.FINER, "Could not check hasSwaRef", e);
-            }
+        if (HAS_SWA_REF_METHOD
+            && context instanceof JAXBContextImpl) {
+            return ((JAXBContextImpl)context).hasSwaRef();
         }
         
         return false;

Modified: incubator/cxf/trunk/rt/transports/http/src/main/java/org/apache/cxf/transport/http/AbstractHTTPDestination.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/transports/http/src/main/java/org/apache/cxf/transport/http/AbstractHTTPDestination.java?view=diff&rev=551723&r1=551722&r2=551723
==============================================================================
--- incubator/cxf/trunk/rt/transports/http/src/main/java/org/apache/cxf/transport/http/AbstractHTTPDestination.java (original)
+++ incubator/cxf/trunk/rt/transports/http/src/main/java/org/apache/cxf/transport/http/AbstractHTTPDestination.java Thu Jun 28 15:24:27 2007
@@ -193,11 +193,20 @@
      * @param headers the current set of headers
      */
     protected void copyResponseHeaders(Message message, HttpServletResponse response) {
+        String ct  = (String)message.get(Message.CONTENT_TYPE);
+        String enc = (String)message.get(Message.ENCODING);
+        
+        if (null != ct 
+            && null != enc
+            && ct.indexOf("charset=") == -1) {
+            ct = ct + "; charset=" + enc;
+        }
+
         Map<?, ?> headers = (Map<?, ?>)message.get(Message.PROTOCOL_HEADERS);
         if (null != headers) {
             
             if (!headers.containsKey(Message.CONTENT_TYPE)) {
-                response.setContentType((String) message.get(Message.CONTENT_TYPE));
+                response.setContentType(ct);
             }
             
             for (Iterator<?> iter = headers.keySet().iterator(); iter.hasNext();) {
@@ -208,7 +217,7 @@
                 }
             }
         } else {
-            response.setContentType((String) message.get(Message.CONTENT_TYPE));
+            response.setContentType(ct);
         }
     }
     
@@ -366,7 +375,8 @@
          */
         public void prepare(Message message) throws IOException {
             message.put(HTTP_RESPONSE, response);
-            message.setContent(OutputStream.class, new WrappedOutputStream(message, response));
+            message.setContent(OutputStream.class, 
+                               new WrappedOutputStream(message, response));
         }
     }
 
@@ -408,6 +418,11 @@
             }
             wrappedStream.close();
             response.flushBuffer();
+        }
+        
+        public void flush() throws IOException {
+            //ignore until we close 
+            // or we'll force chunking and cause all kinds of network packets
         }
     }
 

Modified: incubator/cxf/trunk/rt/transports/http/src/main/java/org/apache/cxf/transport/http/HTTPConduit.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/transports/http/src/main/java/org/apache/cxf/transport/http/HTTPConduit.java?view=diff&rev=551723&r1=551722&r2=551723
==============================================================================
--- incubator/cxf/trunk/rt/transports/http/src/main/java/org/apache/cxf/transport/http/HTTPConduit.java (original)
+++ incubator/cxf/trunk/rt/transports/http/src/main/java/org/apache/cxf/transport/http/HTTPConduit.java Thu Jun 28 15:24:27 2007
@@ -1845,8 +1845,8 @@
             }
             inMessage.put(Message.PROTOCOL_HEADERS, headers);
             inMessage.put(Message.RESPONSE_CODE, responseCode);
-            inMessage.put(Message.CONTENT_TYPE, 
-                    connection.getHeaderField(HttpHeaderHelper.CONTENT_TYPE));
+            inMessage.put(Message.CONTENT_TYPE, connection.getContentType());
+            inMessage.put(Message.ENCODING, connection.getContentEncoding());
             
             if (maintainSession) {
                 String cookieStr = connection.getHeaderField("Set-Cookie");

Modified: incubator/cxf/trunk/rt/transports/http/src/main/java/org/apache/cxf/transport/servlet/ServletDestination.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/transports/http/src/main/java/org/apache/cxf/transport/servlet/ServletDestination.java?view=diff&rev=551723&r1=551722&r2=551723
==============================================================================
--- incubator/cxf/trunk/rt/transports/http/src/main/java/org/apache/cxf/transport/servlet/ServletDestination.java (original)
+++ incubator/cxf/trunk/rt/transports/http/src/main/java/org/apache/cxf/transport/servlet/ServletDestination.java Thu Jun 28 15:24:27 2007
@@ -23,10 +23,8 @@
 import java.util.logging.Level;
 import java.util.logging.Logger;
 
-import javax.servlet.http.HttpServletResponse;
 
 import org.apache.cxf.Bus;
-import org.apache.cxf.message.Message;
 import org.apache.cxf.message.MessageImpl;
 import org.apache.cxf.service.model.EndpointInfo;
 import org.apache.cxf.transport.ConduitInitiator;
@@ -69,26 +67,6 @@
         return LOG;
     }
 
-    /**
-     * Copy the response headers into the response.
-     * 
-     * @param message the current message
-     * @param headers the current set of headers
-     */
-    protected void copyResponseHeaders(Message message, HttpServletResponse response) {
-        String ct = (String) message.get(Message.CONTENT_TYPE);
-        String enc = (String) message.get(Message.ENCODING);
-        
-        if (null != ct) {
-            if (enc != null && ct.indexOf("charset=") == -1) {
-                ct = ct + "; charset=" + enc;
-            }
-            response.setContentType(ct);
-        } else if (enc != null) {
-            response.setContentType("text/xml; charset=" + enc);
-        }
-        
-    }
     
     protected void doMessage(MessageImpl inMessage) throws IOException {
         try {

Modified: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jaxws/ClientServerGreeterNoWsdlTest.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jaxws/ClientServerGreeterNoWsdlTest.java?view=diff&rev=551723&r1=551722&r2=551723
==============================================================================
--- incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jaxws/ClientServerGreeterNoWsdlTest.java (original)
+++ incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jaxws/ClientServerGreeterNoWsdlTest.java Thu Jun 28 15:24:27 2007
@@ -76,7 +76,7 @@
         
         assertEquals(200, httpConnection.getResponseCode());
     
-        assertEquals("text/xml", httpConnection.getContentType());
+        assertEquals("text/xml; charset=utf-8", httpConnection.getContentType());
         assertEquals("OK", httpConnection.getResponseMessage());
         
         InputStream in = httpConnection.getInputStream();

Modified: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jaxws/ClientServerTest.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jaxws/ClientServerTest.java?view=diff&rev=551723&r1=551722&r2=551723
==============================================================================
--- incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jaxws/ClientServerTest.java (original)
+++ incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jaxws/ClientServerTest.java Thu Jun 28 15:24:27 2007
@@ -611,7 +611,7 @@
                 BindingProvider bp = (BindingProvider)greeter;
                 Map<String, Object> responseContext = bp.getResponseContext();
                 String contentType = (String) responseContext.get(Message.CONTENT_TYPE);
-                assertEquals("text/xml", contentType);
+                assertEquals("text/xml; charset=utf-8", contentType);
                 Integer responseCode = (Integer) responseContext.get(Message.RESPONSE_CODE);
                 assertEquals(500, responseCode.intValue());                
                 assertNotNull(brlf.getFaultInfo());
@@ -653,7 +653,7 @@
         
         assertEquals(200, httpConnection.getResponseCode());
         
-        assertEquals("text/xml", httpConnection.getContentType());
+        assertEquals("text/xml; charset=utf-8", httpConnection.getContentType());
         assertEquals("OK", httpConnection.getResponseMessage());
         
         InputStream in = httpConnection.getInputStream();
@@ -682,7 +682,7 @@
         
         assertEquals(200, httpConnection.getResponseCode());
     
-        assertEquals("text/xml", httpConnection.getContentType());
+        assertEquals("text/xml; charset=utf-8", httpConnection.getContentType());
         assertEquals("OK", httpConnection.getResponseMessage());
         
         InputStream in = httpConnection.getInputStream();
@@ -733,7 +733,7 @@
         
         assertEquals(200, httpConnection.getResponseCode());
     
-        assertEquals("text/xml", httpConnection.getContentType());
+        assertEquals("text/xml; charset=utf-8", httpConnection.getContentType());
         assertEquals("OK", httpConnection.getResponseMessage());
         
         InputStream in = httpConnection.getInputStream();

Modified: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jaxws/ClientServerXMLTest.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jaxws/ClientServerXMLTest.java?view=diff&rev=551723&r1=551722&r2=551723
==============================================================================
--- incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jaxws/ClientServerXMLTest.java (original)
+++ incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/jaxws/ClientServerXMLTest.java Thu Jun 28 15:24:27 2007
@@ -128,7 +128,7 @@
 
         assertEquals(200, httpConnection.getResponseCode());
 
-        assertEquals("text/xml", httpConnection.getContentType());
+        assertEquals("text/xml; charset=utf-8", httpConnection.getContentType());
         assertEquals("OK", httpConnection.getResponseMessage());
 
         InputStream in = httpConnection.getInputStream();
@@ -264,7 +264,7 @@
             BindingProvider bp = (BindingProvider) greeter;
             Map<String, Object> responseContext = bp.getResponseContext();
             String contentType = (String) responseContext.get(Message.CONTENT_TYPE);
-            assertEquals("text/xml", contentType);
+            assertEquals("text/xml; charset=utf-8", contentType);
             Integer responseCode = (Integer) responseContext.get(Message.RESPONSE_CODE);
             assertEquals(500, responseCode.intValue());
         }

Modified: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/soap12/Soap12ClientServerTest.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/soap12/Soap12ClientServerTest.java?view=diff&rev=551723&r1=551722&r2=551723
==============================================================================
--- incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/soap12/Soap12ClientServerTest.java (original)
+++ incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/soap12/Soap12ClientServerTest.java Thu Jun 28 15:24:27 2007
@@ -87,7 +87,7 @@
         
         InputStream in = httpConnection.getInputStream();        
         assertNotNull(in);
-        assertEquals("application/soap+xml", httpConnection.getContentType());
+        assertEquals("application/soap+xml; charset=utf-8", httpConnection.getContentType());
        
         Document doc = XMLUtils.parse(in);
         assertNotNull(doc);
@@ -115,7 +115,7 @@
 
         InputStream in = httpConnection.getErrorStream();
         assertNotNull(in);     
-        assertEquals("application/soap+xml", httpConnection.getContentType());
+        assertEquals("application/soap+xml; charset=utf-8", httpConnection.getContentType());
         
         Document doc = XMLUtils.parse(in);
         assertNotNull(doc);        
@@ -152,7 +152,7 @@
         
         assertEquals(500, httpConnection.getResponseCode());
 
-        assertEquals("application/soap+xml", httpConnection.getContentType());
+        assertEquals("application/soap+xml; charset=utf-8", httpConnection.getContentType());
         
         assertEquals("Internal Server Error", httpConnection.getResponseMessage());
 

Modified: incubator/cxf/trunk/tools/common/src/main/java/org/apache/cxf/tools/common/toolspec/ToolRunner.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/tools/common/src/main/java/org/apache/cxf/tools/common/toolspec/ToolRunner.java?view=diff&rev=551723&r1=551722&r2=551723
==============================================================================
--- incubator/cxf/trunk/tools/common/src/main/java/org/apache/cxf/tools/common/toolspec/ToolRunner.java (original)
+++ incubator/cxf/trunk/tools/common/src/main/java/org/apache/cxf/tools/common/toolspec/ToolRunner.java Thu Jun 28 15:24:27 2007
@@ -34,17 +34,17 @@
         // utility class - never constructed
     }
 
-    public static void runTool(Class clz, InputStream toolspecStream,
+    public static void runTool(Class<? extends ToolContainer> clz, InputStream toolspecStream,
                                boolean validate, String[] args) throws Exception {
         runTool(clz, toolspecStream, validate, args, true);
     }
 
-    public static void runTool(Class clz, InputStream toolspecStream,
+    public static void runTool(Class<? extends ToolContainer> clz, InputStream toolspecStream,
                                boolean validate, String[] args, ToolContext context) throws Exception {
         runTool(clz, toolspecStream, validate, args, true, context);
     }
 
-    public static void runTool(Class clz,
+    public static void runTool(Class<? extends ToolContainer> clz,
                                InputStream toolspecStream,
                                boolean validate,
                                String[] args,
@@ -52,43 +52,37 @@
         runTool(clz, toolspecStream, validate, args, true, null);
     }
     
-    public static void runTool(Class clz,
+    public static void runTool(Class<? extends ToolContainer> clz,
                                InputStream toolspecStream,
                                boolean validate,
                                String[] args,
                                boolean exitOnFinish,
                                ToolContext context) throws Exception {
 
-        if (ToolContainer.class.isAssignableFrom(clz)) {
+        ToolContainer container = null;
 
-            ToolContainer container = null;
-
-            try {
-                Constructor cons = clz.getConstructor(
-                                                      new Class[] {
-                                                          ToolSpec.class
-                                                      });
-                container = (ToolContainer)cons.newInstance(
-                                                            new Object[] {
-                                                                new ToolSpec(toolspecStream, validate)
-                                                            });
-            } catch (Exception ex) {
-                Message message = new Message("CLZ_CANNOT_BE_CONSTRUCTED", LOG, clz.getName());
-                LOG.log(Level.SEVERE, message.toString());
-                throw new ToolException(message, ex);
-            }
-
-            try {
-                container.setArguments(args);
-                container.setContext(context);
-                container.execute(exitOnFinish);
-            } catch (Exception ex) {
-                throw ex;
-            }
-        } else {
-            Message message = new Message("CLZ_SHOULD_IMPLEMENT_INTERFACE", LOG, clz.getName());
+        try {
+            Constructor<? extends ToolContainer> cons 
+                = clz.getConstructor(
+                                     new Class[] {
+                                         ToolSpec.class
+                                     });
+            container = cons.newInstance(
+                                        new Object[] {
+                                            new ToolSpec(toolspecStream, validate)
+                                        });
+        } catch (Exception ex) {
+            Message message = new Message("CLZ_CANNOT_BE_CONSTRUCTED", LOG, clz.getName());
             LOG.log(Level.SEVERE, message.toString());
-            throw new ToolException(message);
+            throw new ToolException(message, ex);
+        }
+
+        try {
+            container.setArguments(args);
+            container.setContext(context);
+            container.execute(exitOnFinish);
+        } catch (Exception ex) {
+            throw ex;
         }
 
     }

Modified: incubator/cxf/trunk/tools/common/src/main/java/org/apache/cxf/tools/util/URIParserUtil.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/tools/common/src/main/java/org/apache/cxf/tools/util/URIParserUtil.java?view=diff&rev=551723&r1=551722&r2=551723
==============================================================================
--- incubator/cxf/trunk/tools/common/src/main/java/org/apache/cxf/tools/util/URIParserUtil.java (original)
+++ incubator/cxf/trunk/tools/common/src/main/java/org/apache/cxf/tools/util/URIParserUtil.java Thu Jun 28 15:24:27 2007
@@ -52,7 +52,7 @@
             File file = new File(st.nextToken());
             URL url = null;
             try {
-                url = file.toURL();
+                url = file.toURI().toURL();
             } catch (MalformedURLException e) {
                 e.printStackTrace();
             }

Modified: incubator/cxf/trunk/tools/common/src/test/java/org/apache/cxf/tools/common/toolspec/parser/CommandLineParserTest.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/tools/common/src/test/java/org/apache/cxf/tools/common/toolspec/parser/CommandLineParserTest.java?view=diff&rev=551723&r1=551722&r2=551723
==============================================================================
--- incubator/cxf/trunk/tools/common/src/test/java/org/apache/cxf/tools/common/toolspec/parser/CommandLineParserTest.java (original)
+++ incubator/cxf/trunk/tools/common/src/test/java/org/apache/cxf/tools/common/toolspec/parser/CommandLineParserTest.java Thu Jun 28 15:24:27 2007
@@ -244,7 +244,7 @@
 
     private boolean isQuolifiedVersion() {
         try {
-            Class c = Class.forName("org.apache.xerces.impl.Version");
+            Class<?> c = Class.forName("org.apache.xerces.impl.Version");
             Object o = c.newInstance();
             String v =  (String) c.getMethod("getVersion").invoke(o);
             float vn = Float.parseFloat(StringUtils.getFirstFound(v, "(\\d+.\\d+)"));

Modified: incubator/cxf/trunk/tools/javato/test/src/test/java/org/apache/cxf/tools/java2wsdl/processor/internal/jaxws/WrapperTest.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/tools/javato/test/src/test/java/org/apache/cxf/tools/java2wsdl/processor/internal/jaxws/WrapperTest.java?view=diff&rev=551723&r1=551722&r2=551723
==============================================================================
--- incubator/cxf/trunk/tools/javato/test/src/test/java/org/apache/cxf/tools/java2wsdl/processor/internal/jaxws/WrapperTest.java (original)
+++ incubator/cxf/trunk/tools/javato/test/src/test/java/org/apache/cxf/tools/java2wsdl/processor/internal/jaxws/WrapperTest.java Thu Jun 28 15:24:27 2007
@@ -44,7 +44,7 @@
     @Test
     public void testGetWrapperBeanClassFromMethod() throws Exception {
         String pkgName = "org.apache.cxf.tools.fortest.classnoanno.docwrapped";
-        Class stockClass = Class.forName(pkgName + ".Stock");
+        Class<?> stockClass = Class.forName(pkgName + ".Stock");
         Method method = stockClass.getMethod("getPrice", String.class);
 
         Wrapper wrapper = new Wrapper();
@@ -69,7 +69,7 @@
     @Test
     public void testIsWrapperBeanClassNotExist() throws Exception {
         String pkgName = "org.apache.cxf.tools.fortest.classnoanno.docwrapped";
-        Class stockClass = Class.forName(pkgName + ".Stock");
+        Class<?> stockClass = Class.forName(pkgName + ".Stock");
         Method method = stockClass.getMethod("getPrice", String.class);
         
         Wrapper wrapper = new RequestWrapper();
@@ -93,7 +93,7 @@
         assertEquals("GetPrice", wrapper.getJavaClass().getName());
 
         pkgName = "org.apache.cxf.tools.fortest.withannotation.doc";
-        Class clz = Class.forName(pkgName + ".Greeter");
+        Class<?> clz = Class.forName(pkgName + ".Greeter");
         method = clz.getMethod("sayHi");
 
         wrapper = new RequestWrapper();

Modified: incubator/cxf/trunk/tools/javato/test/src/test/java/org/apache/cxf/tools/java2wsdl/processor/internal/jaxws/WrapperUtilTest.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/tools/javato/test/src/test/java/org/apache/cxf/tools/java2wsdl/processor/internal/jaxws/WrapperUtilTest.java?view=diff&rev=551723&r1=551722&r2=551723
==============================================================================
--- incubator/cxf/trunk/tools/javato/test/src/test/java/org/apache/cxf/tools/java2wsdl/processor/internal/jaxws/WrapperUtilTest.java (original)
+++ incubator/cxf/trunk/tools/javato/test/src/test/java/org/apache/cxf/tools/java2wsdl/processor/internal/jaxws/WrapperUtilTest.java Thu Jun 28 15:24:27 2007
@@ -27,7 +27,7 @@
 
 public class WrapperUtilTest extends Assert {
     String pkgName = "org.apache.cxf.tools.fortest.classnoanno.docwrapped";
-    Class stockClass;
+    Class<?> stockClass;
     Method method;
 
     @Before
@@ -45,7 +45,7 @@
 
     @Test
     public void testWrapperClassNotExists() throws Exception {
-        Class helloClass = Class.forName("org.apache.cxf.tools.fortest.withannotation.doc.HelloWrapped");
+        Class<?> helloClass = Class.forName("org.apache.cxf.tools.fortest.withannotation.doc.HelloWrapped");
         assertNotNull(helloClass);
         Method helloMethod = helloClass.getMethod("sayHiWithoutWrapperClass");
         assertNotNull(helloMethod);

Modified: incubator/cxf/trunk/tools/validator/src/main/java/org/apache/cxf/tools/validator/internal/SchemaValidator.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/tools/validator/src/main/java/org/apache/cxf/tools/validator/internal/SchemaValidator.java?view=diff&rev=551723&r1=551722&r2=551723
==============================================================================
--- incubator/cxf/trunk/tools/validator/src/main/java/org/apache/cxf/tools/validator/internal/SchemaValidator.java (original)
+++ incubator/cxf/trunk/tools/validator/src/main/java/org/apache/cxf/tools/validator/internal/SchemaValidator.java Thu Jun 28 15:24:27 2007
@@ -249,7 +249,7 @@
             List<String> xsdUrls = new ArrayList<String>(files.length);
             for (File file : files) {
                 try {
-                    String s = file.toURL().toString();
+                    String s = file.toURI().toURL().toString();
                     xsdUrls.add(s);
                     if (s.indexOf("http-conf") > 0) {
                         xsdUrls.add(0, s);

Modified: incubator/cxf/trunk/tools/validator/src/main/java/org/apache/cxf/tools/validator/internal/ValidatorUtil.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/tools/validator/src/main/java/org/apache/cxf/tools/validator/internal/ValidatorUtil.java?view=diff&rev=551723&r1=551722&r2=551723
==============================================================================
--- incubator/cxf/trunk/tools/validator/src/main/java/org/apache/cxf/tools/validator/internal/ValidatorUtil.java (original)
+++ incubator/cxf/trunk/tools/validator/src/main/java/org/apache/cxf/tools/validator/internal/ValidatorUtil.java Thu Jun 28 15:24:27 2007
@@ -177,13 +177,13 @@
     private static String getImportedUrl(String theImportPath, String baseURI) throws IOException {
         File file = new File(theImportPath);
         if (file != null && file.exists()) {
-            return file.toURL().toString();
+            return file.toURI().toURL().toString();
         }
         // Import may have a relative path
         File baseFile = new File(baseURI);
         file = new File(baseFile.getParent(), theImportPath);
         if (file != null && file.exists()) {
-            return file.toURL().toString();
+            return file.toURI().toURL().toString();
         }
         return null;
     }

Modified: incubator/cxf/trunk/tools/validator/src/main/java/org/apache/cxf/tools/validator/internal/WSDL11Validator.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/tools/validator/src/main/java/org/apache/cxf/tools/validator/internal/WSDL11Validator.java?view=diff&rev=551723&r1=551722&r2=551723
==============================================================================
--- incubator/cxf/trunk/tools/validator/src/main/java/org/apache/cxf/tools/validator/internal/WSDL11Validator.java (original)
+++ incubator/cxf/trunk/tools/validator/src/main/java/org/apache/cxf/tools/validator/internal/WSDL11Validator.java Thu Jun 28 15:24:27 2007
@@ -183,8 +183,8 @@
                             }
                         });
                     for (int i = 0; i < files.length; i++) {
-                        InputSource is = new InputSource(files[i].toURL().openStream());
-                        is.setSystemId(files[i].toURL().toString());
+                        InputSource is = new InputSource(files[i].toURI().toURL().openStream());
+                        is.setSystemId(files[i].toURI().toURL().toString());
                         xsdList.add(is);
                     }
                 }

Modified: incubator/cxf/trunk/tools/wsdlto/core/src/main/java/org/apache/cxf/tools/wsdlto/WSDLToJava.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/tools/wsdlto/core/src/main/java/org/apache/cxf/tools/wsdlto/WSDLToJava.java?view=diff&rev=551723&r1=551722&r2=551723
==============================================================================
--- incubator/cxf/trunk/tools/wsdlto/core/src/main/java/org/apache/cxf/tools/wsdlto/WSDLToJava.java (original)
+++ incubator/cxf/trunk/tools/wsdlto/core/src/main/java/org/apache/cxf/tools/wsdlto/WSDLToJava.java Thu Jun 28 15:24:27 2007
@@ -27,6 +27,7 @@
 import org.apache.cxf.tools.common.ToolConstants;
 import org.apache.cxf.tools.common.ToolContext;
 import org.apache.cxf.tools.common.ToolException;
+import org.apache.cxf.tools.common.toolspec.ToolContainer;
 import org.apache.cxf.tools.common.toolspec.ToolRunner;
 import org.apache.cxf.tools.wsdlto.core.DataBindingProfile;
 import org.apache.cxf.tools.wsdlto.core.FrontEndProfile;
@@ -95,7 +96,7 @@
         
         context.put(DataBindingProfile.class, databinding);
         
-        Class containerClass = frontend.getContainerClass();
+        Class<? extends ToolContainer> containerClass = frontend.getContainerClass();
 
         InputStream toolspecStream = getResourceAsStream(containerClass, frontend.getToolspec());
          

Modified: incubator/cxf/trunk/tools/wsdlto/core/src/main/java/org/apache/cxf/tools/wsdlto/core/FrontEndProfile.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/tools/wsdlto/core/src/main/java/org/apache/cxf/tools/wsdlto/core/FrontEndProfile.java?view=diff&rev=551723&r1=551722&r2=551723
==============================================================================
--- incubator/cxf/trunk/tools/wsdlto/core/src/main/java/org/apache/cxf/tools/wsdlto/core/FrontEndProfile.java (original)
+++ incubator/cxf/trunk/tools/wsdlto/core/src/main/java/org/apache/cxf/tools/wsdlto/core/FrontEndProfile.java Thu Jun 28 15:24:27 2007
@@ -23,19 +23,20 @@
 import java.util.List;
 import org.apache.cxf.tools.common.FrontEndGenerator;
 import org.apache.cxf.tools.common.Processor;
+import org.apache.cxf.tools.common.toolspec.ToolContainer;
 
 public class FrontEndProfile {
     List<FrontEndGenerator> generators = new ArrayList<FrontEndGenerator>();
     Processor processor;
-    Class containerClz;
+    Class<? extends ToolContainer> containerClz;
     String toolspec;
     AbstractWSDLBuilder<? extends Object> builder;
 
-    public void setContainerClass(Class c) {
+    public void setContainerClass(Class<? extends ToolContainer> c) {
         this.containerClz = c;
     }
 
-    public Class getContainerClass() {
+    public Class<? extends ToolContainer> getContainerClass() {
         return this.containerClz;
     }
 

Modified: incubator/cxf/trunk/tools/wsdlto/core/src/main/java/org/apache/cxf/tools/wsdlto/core/Messages.properties
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/tools/wsdlto/core/src/main/java/org/apache/cxf/tools/wsdlto/core/Messages.properties?view=diff&rev=551723&r1=551722&r2=551723
==============================================================================
--- incubator/cxf/trunk/tools/wsdlto/core/src/main/java/org/apache/cxf/tools/wsdlto/core/Messages.properties (original)
+++ incubator/cxf/trunk/tools/wsdlto/core/src/main/java/org/apache/cxf/tools/wsdlto/core/Messages.properties Thu Jun 28 15:24:27 2007
@@ -44,4 +44,6 @@
 PLUGIN_FILE_NOT_FOUND = Plugin file {0} can not be found
 
 REPLACED_DEFAULT_DATABINDING = Replaced default databinding {0}
-REPLACED_DEFAULT_FRONTEND = Replaced default frontend {0}
\ No newline at end of file
+REPLACED_DEFAULT_FRONTEND = Replaced default frontend {0}
+
+CLZ_SHOULD_IMPLEMENT_INTERFACE = {0} should implement the ToolContainer interface

Modified: incubator/cxf/trunk/tools/wsdlto/core/src/main/java/org/apache/cxf/tools/wsdlto/core/PluginLoader.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/tools/wsdlto/core/src/main/java/org/apache/cxf/tools/wsdlto/core/PluginLoader.java?view=diff&rev=551723&r1=551722&r2=551723
==============================================================================
--- incubator/cxf/trunk/tools/wsdlto/core/src/main/java/org/apache/cxf/tools/wsdlto/core/PluginLoader.java (original)
+++ incubator/cxf/trunk/tools/wsdlto/core/src/main/java/org/apache/cxf/tools/wsdlto/core/PluginLoader.java Thu Jun 28 15:24:27 2007
@@ -44,6 +44,7 @@
 import org.apache.cxf.tools.common.FrontEndGenerator;
 import org.apache.cxf.tools.common.Processor;
 import org.apache.cxf.tools.common.ToolException;
+import org.apache.cxf.tools.common.toolspec.ToolContainer;
 import org.apache.cxf.tools.plugin.DataBinding;
 import org.apache.cxf.tools.plugin.FrontEnd;
 import org.apache.cxf.tools.plugin.Generator;
@@ -284,8 +285,8 @@
         return processor;
     }
 
-    private Class loadContainerClass(String fullClzName) {
-        Class clz = null;
+    private Class<? extends ToolContainer> loadContainerClass(String fullClzName) {
+        Class<?> clz = null;
         try {
             clz = Class.forName(fullClzName);
         } catch (Exception e) {
@@ -293,7 +294,14 @@
             LOG.log(Level.SEVERE, msg.toString());
             throw new ToolException(msg, e);
         }
-        return clz;
+        
+        if (!ToolContainer.class.isAssignableFrom(clz)) {
+            Message message = new Message("CLZ_SHOULD_IMPLEMENT_INTERFACE", LOG, clz.getName());
+            LOG.log(Level.SEVERE, message.toString());
+            throw new ToolException(message);
+        }
+
+        return clz.asSubclass(ToolContainer.class);
     }
 
     private String getFrontEndProfileClass(FrontEnd frontend) {

Modified: incubator/cxf/trunk/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/processor/internal/ProcessorUtil.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/processor/internal/ProcessorUtil.java?view=diff&rev=551723&r1=551722&r2=551723
==============================================================================
--- incubator/cxf/trunk/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/processor/internal/ProcessorUtil.java (original)
+++ incubator/cxf/trunk/tools/wsdlto/frontend/jaxws/src/main/java/org/apache/cxf/tools/wsdlto/frontend/jaxws/processor/internal/ProcessorUtil.java Thu Jun 28 15:24:27 2007
@@ -168,7 +168,7 @@
         if (location.startsWith("http://")) {
             return new URL(location);
         } else {
-            return new File(getAbsolutePath(location)).toURL();
+            return new File(getAbsolutePath(location)).toURI().toURL();
         }
     }
 
@@ -243,7 +243,7 @@
             try {
                 return escapeSpace(new URL(fileOrURL).toExternalForm());
             } catch (MalformedURLException e) {
-                return new File(fileOrURL).getCanonicalFile().toURL().toExternalForm();
+                return new File(fileOrURL).getCanonicalFile().toURI().toURL().toExternalForm();
             }
         } catch (Exception e) {
             return fileOrURL;
@@ -266,7 +266,7 @@
         // absolutize all the system IDs in the input,
         // so that we can map system IDs to DOM trees.
         try {
-            URL baseURL = new File(".").getCanonicalFile().toURL();
+            URL baseURL = new File(".").getCanonicalFile().toURI().toURL();
             return new URL(baseURL, name.replaceAll(" ", "%20")).toExternalForm();
         } catch (IOException e) {
             // ignore

Modified: incubator/cxf/trunk/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenTest.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenTest.java?view=diff&rev=551723&r1=551722&r2=551723
==============================================================================
--- incubator/cxf/trunk/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenTest.java (original)
+++ incubator/cxf/trunk/tools/wsdlto/test/src/test/java/org/apache/cxf/tools/wsdlto/jaxws/CodeGenTest.java Thu Jun 28 15:24:27 2007
@@ -162,7 +162,7 @@
         files = types.listFiles();
         assertEquals(files.length, 3);
 
-        Class clz = classLoader.loadClass("org.apache.hello_world_rpclit.GreeterRPCLit");
+        Class<?> clz = classLoader.loadClass("org.apache.hello_world_rpclit.GreeterRPCLit");
 
         javax.jws.WebService ws = AnnotationUtil.getPrivClassAnnotation(clz, javax.jws.WebService.class);
 
@@ -172,7 +172,7 @@
 
         assertEquals("Generate operation error", 3, clz.getMethods().length);
 
-        Class paraClass = classLoader.loadClass("org.apache.hello_world_rpclit.types.MyComplexStruct");
+        Class<?> paraClass = classLoader.loadClass("org.apache.hello_world_rpclit.types.MyComplexStruct");
         Method method = clz.getMethod("sendReceiveData", new Class[] {paraClass});
         assertEquals("MyComplexStruct", method.getReturnType().getSimpleName());
 
@@ -205,7 +205,7 @@
         File[] files = async.listFiles();
         assertEquals(4, files.length);
 
-        Class clz = classLoader.loadClass("org.apache.hello_world_async_soap_http.GreeterAsync");
+        Class<?> clz = classLoader.loadClass("org.apache.hello_world_async_soap_http.GreeterAsync");
 
         Method method1 = clz.getMethod("greetMeSometimeAsync", new Class[] {java.lang.String.class,
                                                                             javax.xml.ws.AsyncHandler.class});
@@ -243,7 +243,7 @@
         files = types.listFiles();
         assertEquals(7, files.length);
 
-        Class clz = classLoader.loadClass("org.apache.hello_world_soap12_http.Greeter");
+        Class<?> clz = classLoader.loadClass("org.apache.hello_world_soap12_http.Greeter");
         assertTrue("class " + clz.getName() + " modifier is not public", Modifier
             .isPublic(clz.getModifiers()));
         assertTrue("class " + clz.getName() + " modifier is interface", Modifier.isInterface(clz
@@ -307,7 +307,7 @@
         files = types.listFiles();
         assertEquals(17, files.length);
 
-        Class clz = classLoader.loadClass("org.apache.hello_world_soap_http.Greeter");
+        Class<?> clz = classLoader.loadClass("org.apache.hello_world_soap_http.Greeter");
         assertTrue("class " + clz.getName() + " modifier is not public", Modifier
             .isPublic(clz.getModifiers()));
         assertTrue("class " + clz.getName() + " modifier is interface", Modifier.isInterface(clz
@@ -380,7 +380,7 @@
         assertTrue(mapping.exists());
         File[] files = mapping.listFiles();
         assertEquals(9, files.length);
-        Class clz = classLoader.loadClass("org.apache.mapping.SomethingServer");
+        Class<?> clz = classLoader.loadClass("org.apache.mapping.SomethingServer");
         Method method = clz.getMethod("doSomething", new Class[] {int.class, javax.xml.ws.Holder.class,
                                                                   javax.xml.ws.Holder.class});
         assertEquals("boolean", method.getReturnType().getSimpleName());
@@ -417,7 +417,7 @@
         files = schemaImport.listFiles();
         assertEquals(4, files.length);
 
-        Class clz = classLoader.loadClass("org.apache.schema_import.Greeter");
+        Class<?> clz = classLoader.loadClass("org.apache.schema_import.Greeter");
         assertEquals(4, clz.getMethods().length);
 
         Method method = clz.getMethod("pingMe", new Class[] {});
@@ -451,7 +451,7 @@
         files = invoice.listFiles();
         assertEquals(files.length, 9);
 
-        Class clz = classLoader.loadClass("org.apache.invoiceserver.InvoiceServer");
+        Class<?> clz = classLoader.loadClass("org.apache.invoiceserver.InvoiceServer");
         assertEquals(3, clz.getMethods().length);
 
         Method method = clz.getMethod("getInvoicesForCustomer", new Class[] {String.class, String.class});
@@ -534,7 +534,7 @@
         File[] files = apache.listFiles();
         assertEquals(12, files.length);
 
-        Class clz = classLoader.loadClass("org.apache.HeaderTester");
+        Class<?> clz = classLoader.loadClass("org.apache.HeaderTester");
         assertEquals(3, clz.getMethods().length);
 
         SOAPBinding soapBindingAnno = AnnotationUtil.getPrivClassAnnotation(clz, SOAPBinding.class);
@@ -542,7 +542,7 @@
         assertEquals("LITERAL", soapBindingAnno.use().name());
         assertEquals("DOCUMENT", soapBindingAnno.style().name());
 
-        Class para = classLoader.loadClass("org.apache.InoutHeader");
+        Class<?> para = classLoader.loadClass("org.apache.InoutHeader");
 
         Method method = clz.getMethod("inoutHeader", new Class[] {para, Holder.class});
 
@@ -563,7 +563,7 @@
         processor.setContext(env);
         processor.execute();
 
-        Class clz = classLoader.loadClass("org.apache.hello_world_holder.Greeter");
+        Class<?> clz = classLoader.loadClass("org.apache.hello_world_holder.Greeter");
         assertEquals(1, clz.getMethods().length);
 
         SOAPBinding soapBindingAnno = AnnotationUtil.getPrivClassAnnotation(clz, SOAPBinding.class);
@@ -571,7 +571,7 @@
         assertEquals("LITERAL", soapBindingAnno.use().name());
         assertEquals("DOCUMENT", soapBindingAnno.style().name());
 
-        Class para = classLoader.loadClass("org.apache.hello_world_holder.types.GreetMe");
+        Class<?> para = classLoader.loadClass("org.apache.hello_world_holder.types.GreetMe");
         Method method = clz.getMethod("sayHi", new Class[] {Holder.class, para});
         assertEquals("GreetMeResponse", method.getReturnType().getSimpleName());
 
@@ -604,7 +604,7 @@
         File handlerConfig = new File(address, "Greeter_handler.xml");
         assertTrue(handlerConfig.exists());
 
-        Class clz = classLoader.loadClass("ws.address.Greeter");
+        Class<?> clz = classLoader.loadClass("ws.address.Greeter");
         HandlerChain handlerChainAnno = AnnotationUtil.getPrivClassAnnotation(clz, HandlerChain.class);
         assertEquals("Greeter_handler.xml", handlerChainAnno.file());
         assertNotNull("Handler chain xml generate fail!", classLoader
@@ -632,7 +632,7 @@
         files = xsd.listFiles();
         assertEquals(4, files.length);
 
-        Class clz = classLoader
+        Class<?> clz = classLoader
             .loadClass("org.soapinterop.wsdlinteroptestdoclit.WSDLInteropTestDocLitPortType");
 
         Method method = clz.getMethod("echoVoid", new Class[] {});
@@ -661,7 +661,7 @@
         File helloWorld = new File(apache, "hello_world");
         assertTrue(helloWorld.exists());
 
-        Class clz = classLoader.loadClass("org.apache.hello_world.Greeter");
+        Class<?> clz = classLoader.loadClass("org.apache.hello_world.Greeter");
         assertEquals(3, clz.getMethods().length);
 
         Method method = clz.getMethod("pingMe", new Class[] {});
@@ -688,7 +688,7 @@
         File invoice = new File(apache, "invoice");
         assertTrue(invoice.exists());
 
-        Class clz = classLoader.loadClass("org.apache.invoiceserver.NoSuchCustomerFault");
+        Class<?> clz = classLoader.loadClass("org.apache.invoiceserver.NoSuchCustomerFault");
         WebFault webFault = AnnotationUtil.getPrivClassAnnotation(clz, WebFault.class);
         assertEquals("WebFault annotaion name attribute error", "NoSuchCustomer", webFault.name());
 
@@ -718,7 +718,7 @@
         env.put(ToolConstants.CFG_WSDLURL, getLocation("/wsdl2java_wsdl/bug161/header2.wsdl"));
         processor.setContext(env);
         processor.execute();
-        Class clz = classLoader.loadClass("org.apache.header2.Header2Test");
+        Class<?> clz = classLoader.loadClass("org.apache.header2.Header2Test");
         Class header = classLoader.loadClass("org.apache.header2.Header");
         Method method = clz.getMethod("headerMethod", new Class[] {Holder.class, header});
         assertNotNull("method should be generated", method);
@@ -731,7 +731,7 @@
         processor.setContext(env);
         processor.execute();
 
-        Class clz = classLoader.loadClass("org.apache.xml_http_bare.GreetingPortType");
+        Class<?> clz = classLoader.loadClass("org.apache.xml_http_bare.GreetingPortType");
 
         Method method = clz.getMethod("sayHello", new Class[] {java.lang.String.class});
         assertNotNull("sayHello is not be generated", method);
@@ -746,7 +746,7 @@
         env.put(ToolConstants.CFG_WSDLURL, getLocation("/wsdl2java_wsdl/xml_http_wrapped.wsdl"));
         processor.setContext(env);
         processor.execute();
-        Class clz = classLoader.loadClass("org.apache.xml_http_wrapped.GreetingPortType");
+        Class<?> clz = classLoader.loadClass("org.apache.xml_http_wrapped.GreetingPortType");
 
         Method method = clz.getMethod("sayHello", new Class[] {java.lang.String.class});
         assertNotNull("sayHello is not be generated", method);
@@ -761,7 +761,7 @@
         processor.setContext(env);
         processor.execute();
 
-        Class clz = classLoader.loadClass("org.apache.hello_world_doc_lit.Greeter");
+        Class<?> clz = classLoader.loadClass("org.apache.hello_world_doc_lit.Greeter");
 
         Method method = clz.getMethod("greetMe", new Class[] {java.lang.String.class});
         assertNotNull("greetMe is not be generated", method);
@@ -783,8 +783,8 @@
         processor.setContext(env);
         processor.execute();
 
-        Class clz = classLoader.loadClass("org.apache.hello_world_soap_http.Greeter");
-        Class sayHi = classLoader.loadClass("org.apache.hello_world_soap_http.types.SayHi");
+        Class<?> clz = classLoader.loadClass("org.apache.hello_world_soap_http.Greeter");
+        Class<?> sayHi = classLoader.loadClass("org.apache.hello_world_soap_http.types.SayHi");
         Method method = clz.getMethod("_do", new Class[] {sayHi});
         assertNotNull("method which name contains java keywords is not be generated", method);
 
@@ -818,7 +818,7 @@
         env.put(ToolConstants.CFG_BINDING, getLocation("/wsdl2java_wsdl/swa-mime-binding.xml"));
         processor.setContext(env);
         processor.execute();
-        Class clz = classLoader.loadClass("org.apache.cxf.swa.SwAServiceInterface");
+        Class<?> clz = classLoader.loadClass("org.apache.cxf.swa.SwAServiceInterface");
 
         Method method1 = clz.getMethod("echoData", new Class[] {javax.xml.ws.Holder.class,
                                                                 javax.xml.ws.Holder.class});



Mime
View raw message