package org.opendaylight.controller.cluster.datastore.node.utils.stream;
import com.google.common.base.Preconditions;
+import edu.umd.cs.findbugs.annotations.SuppressFBWarnings;
import java.io.DataOutput;
import java.io.IOException;
import java.io.OutputStream;
}
}
+ @SuppressFBWarnings(value = "BC_UNCONFIRMED_CAST",
+ justification = "The casts in the switch clauses are indirectly confirmed via the determination of 'type'.")
@Override
public void writePathArgument(final PathArgument pathArgument) throws IOException {
if (keyValueMap != null && !keyValueMap.isEmpty()) {
output.writeInt(keyValueMap.size());
- for (QName qname : keyValueMap.keySet()) {
- writeQName(qname);
- writeObject(keyValueMap.get(qname));
+ for (Map.Entry<QName, Object> entry : keyValueMap.entrySet()) {
+ writeQName(entry.getKey());
+ writeObject(entry.getValue());
}
} else {
output.writeInt(0);