Sonar related fixes
- suppress SONAR warning for printing stack trace in CLI
- add string constants for the Sonar suppression identifiers
Change-Id: I03992f89675f9d074347042b7a196dbcc1036c28
diff --git a/utils/misc/src/main/java/org/onlab/packet/IGMP.java b/utils/misc/src/main/java/org/onlab/packet/IGMP.java
index cabd252..938cd6e 100644
--- a/utils/misc/src/main/java/org/onlab/packet/IGMP.java
+++ b/utils/misc/src/main/java/org/onlab/packet/IGMP.java
@@ -15,21 +15,21 @@
*/
package org.onlab.packet;
-import org.slf4j.Logger;
-
import java.nio.ByteBuffer;
import java.util.ArrayList;
+import java.util.Arrays;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
-import java.util.Arrays;
+
+import org.slf4j.Logger;
import static com.google.common.base.MoreObjects.toStringHelper;
import static com.google.common.base.Preconditions.checkNotNull;
import static org.onlab.packet.PacketUtils.checkInput;
+import static org.onlab.util.SonarSuppressionConstants.SONAR_SWITCH_FALLTHROUGH;
import static org.slf4j.LoggerFactory.getLogger;
-
/**
* Implements IGMP control packet format.
*/
@@ -156,7 +156,7 @@
*
* @return the serialized IGMP message
*/
- @java.lang.SuppressWarnings("squid:S128") // suppress switch fall through warning
+ @java.lang.SuppressWarnings(SONAR_SWITCH_FALLTHROUGH) // suppress switch fall through warning
@Override
public byte[] serialize() {
byte [] data = new byte[8915];