sal-binding-it: use lambdas
[controller.git] / opendaylight / md-sal / sal-binding-it / src / test / java / org / opendaylight / controller / test / sal / binding / it / RoutedServiceIT.java
index 0b365ca..a394bcb 100644 (file)
@@ -17,7 +17,6 @@ import com.google.common.util.concurrent.Futures;
 import org.junit.Before;
 import org.junit.Test;
 import org.mockito.Mockito;
-import org.opendaylight.controller.sal.binding.api.BindingAwareBroker.ConsumerContext;
 import org.opendaylight.controller.sal.binding.api.BindingAwareBroker.ProviderContext;
 import org.opendaylight.controller.sal.binding.api.BindingAwareBroker.RoutedRpcRegistration;
 import org.opendaylight.controller.sal.binding.api.BindingAwareConsumer;
@@ -96,12 +95,8 @@ public class RoutedServiceIT extends AbstractIT {
         assertSame(odlRoutedService2, secondReg.getInstance());
         assertNotSame(secondReg, firstReg);
 
-        final BindingAwareConsumer consumer = new BindingAwareConsumer() {
-            @Override
-            public void onSessionInitialized(final ConsumerContext session) {
-                consumerService = session.getRpcService(OpendaylightTestRoutedRpcService.class);
-            }
-        };
+        final BindingAwareConsumer consumer =
+                session -> consumerService = session.getRpcService(OpendaylightTestRoutedRpcService.class);
         LOG.info("Register routeService consumer");
         broker.registerConsumer(consumer);
 

©2013 OpenDaylight, A Linux Foundation Collaborative Project. All Rights Reserved.
OpenDaylight is a registered trademark of The OpenDaylight Project, Inc.
Linux Foundation and OpenDaylight are registered trademarks of the Linux Foundation.
Linux is a registered trademark of Linus Torvalds.