cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dk...@apache.org
Subject svn commit: r760171 - /cxf/trunk/tools/validator/src/main/java/org/apache/cxf/tools/validator/internal/WSDL11Validator.java
Date Mon, 30 Mar 2009 21:02:53 GMT
Author: dkulp
Date: Mon Mar 30 21:02:52 2009
New Revision: 760171

URL: http://svn.apache.org/viewvc?rev=760171&view=rev
Log:
When validating a wsdl, collect all the errors and spit them all out, not just the first.

Modified:
    cxf/trunk/tools/validator/src/main/java/org/apache/cxf/tools/validator/internal/WSDL11Validator.java

Modified: cxf/trunk/tools/validator/src/main/java/org/apache/cxf/tools/validator/internal/WSDL11Validator.java
URL: http://svn.apache.org/viewvc/cxf/trunk/tools/validator/src/main/java/org/apache/cxf/tools/validator/internal/WSDL11Validator.java?rev=760171&r1=760170&r2=760171&view=diff
==============================================================================
--- cxf/trunk/tools/validator/src/main/java/org/apache/cxf/tools/validator/internal/WSDL11Validator.java
(original)
+++ cxf/trunk/tools/validator/src/main/java/org/apache/cxf/tools/validator/internal/WSDL11Validator.java
Mon Mar 30 21:02:52 2009
@@ -129,12 +129,16 @@
             validators.add(new MIMEBindingValidator(this.def));
         }
 
+        boolean notValid = false;
         for (AbstractValidator validator : validators) {
             if (!validator.isValid()) {
+                notValid = true;
                 addErrorMessage(validator.getErrorMessage());                
-                throw new ToolException(this.getErrorMessage());
             }
         }
+        if (notValid) {
+            throw new ToolException(this.getErrorMessage());            
+        }
 
         // By default just use WsdlRefValidator
         if (!env.optionSet(ToolConstants.CFG_VALIDATE_WSDL)) {



Mime
View raw message