jmeter-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From pmoua...@apache.org
Subject svn commit: r1776886 - in /jmeter/trunk/src/protocol: jms/org/apache/jmeter/protocol/jms/control/gui/ jms/org/apache/jmeter/protocol/jms/sampler/ ldap/org/apache/jmeter/protocol/ldap/sampler/ mail/org/apache/jmeter/protocol/smtp/sampler/protocol/ tcp/o...
Date Sun, 01 Jan 2017 21:26:04 GMT
Author: pmouawad
Date: Sun Jan  1 21:26:03 2017
New Revision: 1776886

URL: http://svn.apache.org/viewvc?rev=1776886&view=rev
Log:
Sonar : fix squid:UselessParenthesesCheck Remove those useless parentheses.

Modified:
    jmeter/trunk/src/protocol/jms/org/apache/jmeter/protocol/jms/control/gui/JMSPropertiesPanel.java
    jmeter/trunk/src/protocol/jms/org/apache/jmeter/protocol/jms/sampler/BaseJMSSampler.java
    jmeter/trunk/src/protocol/jms/org/apache/jmeter/protocol/jms/sampler/SubscriberSampler.java
    jmeter/trunk/src/protocol/ldap/org/apache/jmeter/protocol/ldap/sampler/LDAPSampler.java
    jmeter/trunk/src/protocol/mail/org/apache/jmeter/protocol/smtp/sampler/protocol/SendMailCommand.java
    jmeter/trunk/src/protocol/tcp/org/apache/jmeter/protocol/tcp/sampler/TCPSampler.java

Modified: jmeter/trunk/src/protocol/jms/org/apache/jmeter/protocol/jms/control/gui/JMSPropertiesPanel.java
URL: http://svn.apache.org/viewvc/jmeter/trunk/src/protocol/jms/org/apache/jmeter/protocol/jms/control/gui/JMSPropertiesPanel.java?rev=1776886&r1=1776885&r2=1776886&view=diff
==============================================================================
--- jmeter/trunk/src/protocol/jms/org/apache/jmeter/protocol/jms/control/gui/JMSPropertiesPanel.java
(original)
+++ jmeter/trunk/src/protocol/jms/org/apache/jmeter/protocol/jms/control/gui/JMSPropertiesPanel.java
Sun Jan  1 21:26:03 2017
@@ -212,7 +212,7 @@ public class JMSPropertiesPanel extends
     }
 
     private JPanel createButtonPanel() {
-        boolean tableEmpty = (tableModel.getRowCount() == 0);
+        boolean tableEmpty = tableModel.getRowCount() == 0;
 
         addButton = createButton("add", 'A', ADD_COMMAND, true); //$NON-NLS-1$
         deleteButton = createButton("delete", 'D', DELETE_COMMAND, !tableEmpty); //$NON-NLS-1$

Modified: jmeter/trunk/src/protocol/jms/org/apache/jmeter/protocol/jms/sampler/BaseJMSSampler.java
URL: http://svn.apache.org/viewvc/jmeter/trunk/src/protocol/jms/org/apache/jmeter/protocol/jms/sampler/BaseJMSSampler.java?rev=1776886&r1=1776885&r2=1776886&view=diff
==============================================================================
--- jmeter/trunk/src/protocol/jms/org/apache/jmeter/protocol/jms/sampler/BaseJMSSampler.java
(original)
+++ jmeter/trunk/src/protocol/jms/org/apache/jmeter/protocol/jms/sampler/BaseJMSSampler.java
Sun Jan  1 21:26:03 2017
@@ -347,8 +347,8 @@ public abstract class BaseJMSSampler ext
             final Destination destination = message.getJMSDestination();
 
             response.append("\n   Destination: ");
-            response.append((destination == null ? null : destination
-                .toString()));
+            response.append(destination == null ? null : destination
+                .toString());
 
             response.append("\n   Expiration: ");
             response.append(new Date(message.getJMSExpiration()));
@@ -364,7 +364,7 @@ public abstract class BaseJMSSampler ext
 
             final Destination replyTo = message.getJMSReplyTo();
             response.append("\n   Reply to: ");
-            response.append((replyTo == null ? null : replyTo.toString()));
+            response.append(replyTo == null ? null : replyTo.toString());
 
             response.append("\n   Timestamp: ");
             response.append(new Date(message.getJMSTimestamp()));

Modified: jmeter/trunk/src/protocol/jms/org/apache/jmeter/protocol/jms/sampler/SubscriberSampler.java
URL: http://svn.apache.org/viewvc/jmeter/trunk/src/protocol/jms/org/apache/jmeter/protocol/jms/sampler/SubscriberSampler.java?rev=1776886&r1=1776885&r2=1776886&view=diff
==============================================================================
--- jmeter/trunk/src/protocol/jms/org/apache/jmeter/protocol/jms/sampler/SubscriberSampler.java
(original)
+++ jmeter/trunk/src/protocol/jms/org/apache/jmeter/protocol/jms/sampler/SubscriberSampler.java
Sun Jan  1 21:26:03 2017
@@ -180,7 +180,7 @@ public class SubscriberSampler extends B
                 msg = SUBSCRIBER.getMessage(calculateWait(until, now));
                 if (msg != null){
                     read++;
-                    extractContent(buffer, propBuffer, msg, (read == loop));
+                    extractContent(buffer, propBuffer, msg, read == loop);
                 }
             } catch (JMSException e) {
                 log.warn("Error "+e.toString());

Modified: jmeter/trunk/src/protocol/ldap/org/apache/jmeter/protocol/ldap/sampler/LDAPSampler.java
URL: http://svn.apache.org/viewvc/jmeter/trunk/src/protocol/ldap/org/apache/jmeter/protocol/ldap/sampler/LDAPSampler.java?rev=1776886&r1=1776885&r2=1776886&view=diff
==============================================================================
--- jmeter/trunk/src/protocol/ldap/org/apache/jmeter/protocol/ldap/sampler/LDAPSampler.java
(original)
+++ jmeter/trunk/src/protocol/ldap/org/apache/jmeter/protocol/ldap/sampler/LDAPSampler.java
Sun Jan  1 21:26:03 2017
@@ -357,7 +357,7 @@ public class LDAPSampler extends Abstrac
      * @return a formatted string label describing this sampler
      */
     public String getLabel() {
-        return ("ldap://" + this.getServername() + ":" + getPort() + "/" + this.getRootdn());
+        return "ldap://" + this.getServername() + ":" + getPort() + "/" + this.getRootdn();
     }
 
     /**

Modified: jmeter/trunk/src/protocol/mail/org/apache/jmeter/protocol/smtp/sampler/protocol/SendMailCommand.java
URL: http://svn.apache.org/viewvc/jmeter/trunk/src/protocol/mail/org/apache/jmeter/protocol/smtp/sampler/protocol/SendMailCommand.java?rev=1776886&r1=1776885&r2=1776886&view=diff
==============================================================================
--- jmeter/trunk/src/protocol/mail/org/apache/jmeter/protocol/smtp/sampler/protocol/SendMailCommand.java
(original)
+++ jmeter/trunk/src/protocol/mail/org/apache/jmeter/protocol/smtp/sampler/protocol/SendMailCommand.java
Sun Jan  1 21:26:03 2017
@@ -729,7 +729,7 @@ public class SendMailCommand {
      * @return Protocol that is used to transport message
      */
     private String getProtocol() {
-        return (useSSL) ? "smtps" : "smtp";
+        return useSSL ? "smtps" : "smtp";
     }
 
     /**

Modified: jmeter/trunk/src/protocol/tcp/org/apache/jmeter/protocol/tcp/sampler/TCPSampler.java
URL: http://svn.apache.org/viewvc/jmeter/trunk/src/protocol/tcp/org/apache/jmeter/protocol/tcp/sampler/TCPSampler.java?rev=1776886&r1=1776885&r2=1776886&view=diff
==============================================================================
--- jmeter/trunk/src/protocol/tcp/org/apache/jmeter/protocol/tcp/sampler/TCPSampler.java (original)
+++ jmeter/trunk/src/protocol/tcp/org/apache/jmeter/protocol/tcp/sampler/TCPSampler.java Sun
Jan  1 21:26:03 2017
@@ -315,7 +315,7 @@ public class TCPSampler extends Abstract
      * @return a formatted string label describing this sampler
      */
     public String getLabel() {
-        return ("tcp://" + this.getServer() + ":" + this.getPort());//$NON-NLS-1$ $NON-NLS-2$
+        return "tcp://" + this.getServer() + ":" + this.getPort();//$NON-NLS-1$ $NON-NLS-2$
     }
 
     private Class<?> getClass(String className) {



Mime
View raw message