This fixes up the issues reported and flips enforcement to on.
Change-Id: I205b07535f42f6a3f3c5ae4e14167de4982e9338
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
<version>6.0.0-SNAPSHOT</version>
<packaging>bundle</packaging>
- <properties>
- <!-- FIXME: we have some violations here -->
- <odlparent.spotbugs.enforce>false</odlparent.spotbugs.enforce>
- </properties>
-
<dependencies>
<dependency>
<groupId>org.opendaylight.mdsal</groupId>
import org.opendaylight.yangtools.yang.common.Uint64
import org.opendaylight.yangtools.yang.common.Uint8
import org.opendaylight.yangtools.yang.model.api.type.BitsTypeDefinition
+import edu.umd.cs.findbugs.annotations.SuppressFBWarnings
/**
* Template for generating JAVA class.
«ENDIF»
'''
+ @SuppressFBWarnings(value = "DLS_DEAD_LOCAL_STORE", justification = "FOR with SEPARATOR, not needing for value")
def protected bitsArgs() '''
«JU_LIST.importedName»<«STRING.importedName»> properties = «Lists.importedName».newArrayList(«allProperties.propsAsArgs»);
if (!properties.contains(defaultValue)) {
import static java.util.Objects.requireNonNull;
import com.google.common.collect.ImmutableList;
+import edu.umd.cs.findbugs.annotations.SuppressFBWarnings;
import java.util.ArrayDeque;
import java.util.Deque;
import java.util.Iterator;
return sb.toString();
}
+ @SuppressFBWarnings(value = "NP_NONNULL_RETURN_VIOLATION",
+ justification = "SpotBugs confusion @Nullable vs @NonNullByDefault")
private @Nullable List<String> findDescandantPath(final JavaTypeName type) {
Optional<JavaTypeName> optEnclosing = type.immediatelyEnclosingClass();
verify(optEnclosing.isPresent());