jmeter-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From pmoua...@apache.org
Subject svn commit: r1688056 - in /jmeter/trunk/src/core/org/apache/jmeter/save: CSVSaveService.java SaveService.java ScriptWrapperConverter.java
Date Sun, 28 Jun 2015 20:14:51 GMT
Author: pmouawad
Date: Sun Jun 28 20:14:51 2015
New Revision: 1688056

URL: http://svn.apache.org/r1688056
Log:
Java7 multiple exception catching

Modified:
    jmeter/trunk/src/core/org/apache/jmeter/save/CSVSaveService.java
    jmeter/trunk/src/core/org/apache/jmeter/save/SaveService.java
    jmeter/trunk/src/core/org/apache/jmeter/save/ScriptWrapperConverter.java

Modified: jmeter/trunk/src/core/org/apache/jmeter/save/CSVSaveService.java
URL: http://svn.apache.org/viewvc/jmeter/trunk/src/core/org/apache/jmeter/save/CSVSaveService.java?rev=1688056&r1=1688055&r2=1688056&view=diff
==============================================================================
--- jmeter/trunk/src/core/org/apache/jmeter/save/CSVSaveService.java (original)
+++ jmeter/trunk/src/core/org/apache/jmeter/save/CSVSaveService.java Sun Jun 28 20:14:51 2015
@@ -363,11 +363,7 @@ public final class CSVSaveService {
                         + ". Extra fields have been ignored.");
             }
 
-        } catch (NumberFormatException e) {
-            log.warn("Error parsing field '" + field + "' at line "
-                    + lineNumber + " " + e);
-            throw new JMeterError(e);
-        } catch (ParseException e) {
+        } catch (NumberFormatException|ParseException e) {
             log.warn("Error parsing field '" + field + "' at line "
                     + lineNumber + " " + e);
             throw new JMeterError(e);

Modified: jmeter/trunk/src/core/org/apache/jmeter/save/SaveService.java
URL: http://svn.apache.org/viewvc/jmeter/trunk/src/core/org/apache/jmeter/save/SaveService.java?rev=1688056&r1=1688055&r2=1688056&view=diff
==============================================================================
--- jmeter/trunk/src/core/org/apache/jmeter/save/SaveService.java (original)
+++ jmeter/trunk/src/core/org/apache/jmeter/save/SaveService.java Sun Jun 28 20:14:51 2015
@@ -253,19 +253,8 @@ public class SaveService {
                                 registerConverter(key, JMXSAVER, false);
                                 registerConverter(key, JTLSAVER, false);
                             }
-                        } catch (IllegalAccessException e1) {
-                            log.warn("Can't register a converter: " + key, e1);
-                        } catch (InstantiationException e1) {
-                            log.warn("Can't register a converter: " + key, e1);
-                        } catch (ClassNotFoundException e1) {
-                            log.warn("Can't register a converter: " + key, e1);
-                        } catch (IllegalArgumentException e1) {
-                            log.warn("Can't register a converter: " + key, e1);
-                        } catch (SecurityException e1) {
-                            log.warn("Can't register a converter: " + key, e1);
-                        } catch (InvocationTargetException e1) {
-                            log.warn("Can't register a converter: " + key, e1);
-                        } catch (NoSuchMethodException e1) {
+                        } catch (IllegalAccessException|InstantiationException|ClassNotFoundException|IllegalArgumentException|
+                                SecurityException|InvocationTargetException|NoSuchMethodException
e1) {
                             log.warn("Can't register a converter: " + key, e1);
                         }
                     }

Modified: jmeter/trunk/src/core/org/apache/jmeter/save/ScriptWrapperConverter.java
URL: http://svn.apache.org/viewvc/jmeter/trunk/src/core/org/apache/jmeter/save/ScriptWrapperConverter.java?rev=1688056&r1=1688055&r2=1688056&view=diff
==============================================================================
--- jmeter/trunk/src/core/org/apache/jmeter/save/ScriptWrapperConverter.java (original)
+++ jmeter/trunk/src/core/org/apache/jmeter/save/ScriptWrapperConverter.java Sun Jun 28 20:14:51
2015
@@ -93,9 +93,7 @@ public class ScriptWrapperConverter impl
         // Catch errors and rethrow as ConversionException so we get location details
         try {
             wrap.testPlan = (HashTree) context.convertAnother(wrap, getNextType(reader));
-        } catch (NoClassDefFoundError e) {
-            throw createConversionException(e);
-        } catch (Exception e) {
+        } catch (NoClassDefFoundError|Exception e) {
             throw createConversionException(e);
         }
         return wrap;



Mime
View raw message