Switch to MD-SAL APIs
[openflowplugin.git] / applications / notification-supplier / src / main / java / org / opendaylight / openflowplugin / applications / notification / supplier / impl / item / GroupNotificationSupplierImpl.java
index 877ceb1ba07ef9a72e865b00f98e1f6d02adb7c9..50e4345df53d775d3fcbef94014e7e747fbdf0a5 100644 (file)
@@ -5,12 +5,11 @@
  * 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.openflowplugin.applications.notification.supplier.impl.item;
 
 import com.google.common.base.Preconditions;
-import org.opendaylight.controller.md.sal.binding.api.DataBroker;
-import org.opendaylight.controller.sal.binding.api.NotificationProviderService;
+import org.opendaylight.mdsal.binding.api.DataBroker;
+import org.opendaylight.mdsal.binding.api.NotificationPublishService;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.flow.inventory.rev130819.FlowCapableNode;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.group.service.rev130918.GroupAdded;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.group.service.rev130918.GroupAddedBuilder;
@@ -20,7 +19,6 @@ import org.opendaylight.yang.gen.v1.urn.opendaylight.group.service.rev130918.Gro
 import org.opendaylight.yang.gen.v1.urn.opendaylight.group.service.rev130918.GroupUpdatedBuilder;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.group.types.rev131018.GroupRef;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.group.types.rev131018.groups.Group;
-import org.opendaylight.yang.gen.v1.urn.opendaylight.group.types.rev131018.groups.GroupKey;
 import org.opendaylight.yangtools.yang.binding.InstanceIdentifier;
 
 /**
@@ -36,10 +34,10 @@ public class GroupNotificationSupplierImpl extends AbstractNotificationSupplierF
     /**
      * Constructor register supplier as DataTreeChangeListener and create wildCarded InstanceIdentifier.
      *
-     * @param notifProviderService - {@link NotificationProviderService}
+     * @param notifProviderService - {@link NotificationPublishService}
      * @param db                   - {@link DataBroker}
      */
-    public GroupNotificationSupplierImpl(final NotificationProviderService notifProviderService, final DataBroker db) {
+    public GroupNotificationSupplierImpl(final NotificationPublishService notifProviderService, final DataBroker db) {
         super(notifProviderService, db, Group.class);
     }
 
@@ -72,7 +70,7 @@ public class GroupNotificationSupplierImpl extends AbstractNotificationSupplierF
     public GroupRemoved deleteNotification(final InstanceIdentifier<Group> path) {
         Preconditions.checkArgument(path != null);
         final GroupRemovedBuilder builder = new GroupRemovedBuilder();
-        builder.setGroupId(path.firstKeyOf(Group.class, GroupKey.class).getGroupId());
+        builder.setGroupId(path.firstKeyOf(Group.class).getGroupId());
         builder.setGroupRef(new GroupRef(path));
         builder.setNode(createNodeRef(path));
         return builder.build();