Fix raw type warnings in bgp/bmp
[bgpcep.git] / bmp / bmp-impl / src / main / java / org / opendaylight / protocol / bmp / impl / BmpMessageToByteEncoder.java
index 3829d8558c922a0d535cc81355a0428443fc9cb1..2763b7b9a20974d4c590faea4a35c0a0a90fc45e 100644 (file)
@@ -5,7 +5,6 @@
  * terms of the Eclipse Public License v1.0 which accompanies this distribution,
  * and is available at http://www.eclipse.org/legal/epl-v10.html
  */
-
 package org.opendaylight.protocol.bmp.impl;
 
 import static java.util.Objects.requireNonNull;
@@ -20,8 +19,7 @@ import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
 @Sharable
-public final class BmpMessageToByteEncoder extends MessageToByteEncoder<Notification> {
-
+public final class BmpMessageToByteEncoder extends MessageToByteEncoder<Notification<?>> {
     private static final Logger LOG = LoggerFactory.getLogger(BmpMessageToByteEncoder.class);
 
     private final BmpMessageRegistry registry;
@@ -31,11 +29,9 @@ public final class BmpMessageToByteEncoder extends MessageToByteEncoder<Notifica
     }
 
     @Override
-    protected void encode(final ChannelHandlerContext ctx, final Notification message, final ByteBuf out)
-        throws Exception {
+    protected void encode(final ChannelHandlerContext ctx, final Notification<?> message, final ByteBuf out) {
         LOG.trace("Encoding message: {}", message);
-        this.registry.serializeMessage(message, out);
+        registry.serializeMessage(message, out);
         LOG.debug("Message sent to output: {}", message);
     }
-
 }