diff --git a/incubator/api/src/main/java/org/onosproject/incubator/net/virtual/event/AbstractVirtualListenerManager.java b/incubator/api/src/main/java/org/onosproject/incubator/net/virtual/event/AbstractVirtualListenerManager.java
index e87876c..866e845 100644
--- a/incubator/api/src/main/java/org/onosproject/incubator/net/virtual/event/AbstractVirtualListenerManager.java
+++ b/incubator/api/src/main/java/org/onosproject/incubator/net/virtual/event/AbstractVirtualListenerManager.java
@@ -29,9 +29,7 @@
  */
 public abstract class AbstractVirtualListenerManager
         <E extends Event, L extends EventListener<E>>
-    implements ListenerService<E, L>, VnetService {
-
-    private static final String NETWORK_NULL = "Network ID cannot be null";
+        implements ListenerService<E, L>, VnetService {
 
     protected final NetworkId networkId;
     protected final VirtualNetworkService manager;
@@ -39,29 +37,34 @@
 
     protected EventDeliveryService eventDispatcher;
 
-    VirtualListenerRegistryManager listenerManager =
+    private VirtualListenerRegistryManager listenerManager =
             VirtualListenerRegistryManager.getInstance();
 
+    private Class<? extends Event> eventClass;
+
     public AbstractVirtualListenerManager(VirtualNetworkService manager,
-                                          NetworkId networkId) {
+                                          NetworkId networkId,
+                                          Class<? extends Event> eventClass) {
         this.manager = manager;
         this.networkId = networkId;
         this.serviceDirectory = manager.getServiceDirectory();
 
+        this.eventClass = eventClass;
+
         //Set default event delivery service by default
         this.eventDispatcher = serviceDirectory.get(EventDeliveryService.class);
     }
 
     @Override
+    @SuppressWarnings("unchecked")
     public void addListener(L listener) {
-        listenerManager.getRegistry(networkId, getEventClass())
-                .addListener(listener);
+        listenerManager.getRegistry(networkId, eventClass).addListener(listener);
     }
 
     @Override
+    @SuppressWarnings("unchecked")
     public void removeListener(L listener) {
-        listenerManager.getRegistry(networkId, getEventClass())
-                .removeListener(listener);
+        listenerManager.getRegistry(networkId, eventClass).removeListener(listener);
     }
 
     /**
@@ -83,23 +86,4 @@
     public NetworkId networkId() {
         return this.networkId;
     }
-
-    /**
-     * Returns the class type of parameter type.
-     * More specifically, it returns the class type of event class.
-     *
-     * @return the class type of provider service of the service
-     */
-    public Class getEventClass() {
-        String className = this.getClass().getGenericSuperclass().toString();
-        String pramType = className.split("<")[1].split(",")[0];
-
-        try {
-            return Class.forName(pramType);
-        } catch (ClassNotFoundException e) {
-            e.printStackTrace();
-        }
-
-        return null;
-    }
 }
diff --git a/incubator/api/src/main/java/org/onosproject/incubator/net/virtual/event/VirtualListenerRegistryManager.java b/incubator/api/src/main/java/org/onosproject/incubator/net/virtual/event/VirtualListenerRegistryManager.java
index 9d01a00..252d466 100644
--- a/incubator/api/src/main/java/org/onosproject/incubator/net/virtual/event/VirtualListenerRegistryManager.java
+++ b/incubator/api/src/main/java/org/onosproject/incubator/net/virtual/event/VirtualListenerRegistryManager.java
@@ -72,8 +72,10 @@
 
         ListenerRegistry listenerRegistry =
                 listenerMapByNetwork.get(networkId).get(originalEvent.getClass());
-        listenerRegistry.process(originalEvent);
-        lastStart = listenerRegistry;
+        if (listenerRegistry != null) {
+            listenerRegistry.process(originalEvent);
+            lastStart = listenerRegistry;
+        }
     }
 
     @Override
diff --git a/incubator/api/src/test/java/org/onosproject/incubator/net/virtual/event/AbstractVirtualListenerManagerTest.java b/incubator/api/src/test/java/org/onosproject/incubator/net/virtual/event/AbstractVirtualListenerManagerTest.java
index 23934b5..6614941 100644
--- a/incubator/api/src/test/java/org/onosproject/incubator/net/virtual/event/AbstractVirtualListenerManagerTest.java
+++ b/incubator/api/src/test/java/org/onosproject/incubator/net/virtual/event/AbstractVirtualListenerManagerTest.java
@@ -38,6 +38,7 @@
 import org.onosproject.incubator.net.virtual.VirtualNetworkService;
 import org.onosproject.incubator.net.virtual.VirtualPort;
 import org.onosproject.net.DeviceId;
+import org.osgi.framework.BundleContext;
 
 import java.util.ArrayList;
 import java.util.List;
@@ -52,24 +53,22 @@
  */
 public class AbstractVirtualListenerManagerTest {
 
-    private VirtualNetworkService manager;
-
-    TestEventDispatcher dispatcher = new TestEventDispatcher();
-    VirtualListenerRegistryManager listenerRegistryManager =
+    private TestEventDispatcher dispatcher = new TestEventDispatcher();
+    private VirtualListenerRegistryManager listenerRegistryManager =
             VirtualListenerRegistryManager.getInstance();
 
-    PrickleManager prickleManager;
-    PrickleListener prickleListener;
+    private PrickleManager prickleManager;
+    private PrickleListener prickleListener;
 
-    GooManager gooManager;
-    GooListener gooListener;
+    private GooManager gooManager;
+    private GooListener gooListener;
 
-    BarManager barManager;
-    BarListener barListener;
+    private BarManager barManager;
+    private BarListener barListener;
 
     @Before
     public void setUp() {
-        manager = new TestVirtualNetworkManager();
+        VirtualNetworkService manager = new TestVirtualNetworkManager();
 
         dispatcher.addSink(VirtualEvent.class, listenerRegistryManager);
 
@@ -153,25 +152,25 @@
     private enum Type { FOO }
 
     private static class Thing extends AbstractEvent<Type, String> {
-        protected Thing(String subject) {
+        private Thing(String subject) {
             super(Type.FOO, subject);
         }
     }
 
     private static class Prickle extends Thing {
-        protected Prickle(String subject) {
+        private Prickle(String subject) {
             super(subject);
         }
     }
 
     private static class Goo extends Thing {
-        protected Goo(String subject) {
+        private Goo(String subject) {
             super(subject);
         }
     }
 
     private static class Bar extends Thing {
-        protected Bar(String subject) {
+        private Bar(String subject) {
             super(subject);
         }
     }
@@ -198,19 +197,19 @@
 
     private class PrickleManager extends AbstractVirtualListenerManager<Prickle, PrickleListener> {
         public PrickleManager(VirtualNetworkService service, NetworkId networkId) {
-            super(service, networkId);
+            super(service, networkId, Prickle.class);
         }
     }
 
     private class GooManager extends AbstractVirtualListenerManager<Goo, GooListener> {
         public GooManager(VirtualNetworkService service, NetworkId networkId) {
-            super(service, networkId);
+            super(service, networkId, Goo.class);
         }
     }
 
     private class BarManager extends AbstractVirtualListenerManager<Bar, BarListener> {
         public BarManager(VirtualNetworkService service, NetworkId networkId) {
-            super(service, networkId);
+            super(service, networkId, Bar.class);
         }
     }
 
diff --git a/incubator/net/src/main/java/org/onosproject/incubator/net/virtual/impl/VirtualNetworkDeviceManager.java b/incubator/net/src/main/java/org/onosproject/incubator/net/virtual/impl/VirtualNetworkDeviceManager.java
index c529061..0f47a29 100644
--- a/incubator/net/src/main/java/org/onosproject/incubator/net/virtual/impl/VirtualNetworkDeviceManager.java
+++ b/incubator/net/src/main/java/org/onosproject/incubator/net/virtual/impl/VirtualNetworkDeviceManager.java
@@ -61,7 +61,7 @@
      */
     public VirtualNetworkDeviceManager(VirtualNetworkService virtualNetworkManager,
                                        NetworkId networkId) {
-        super(virtualNetworkManager, networkId);
+        super(virtualNetworkManager, networkId, DeviceEvent.class);
         manager.addListener(virtualNetworkListener);
     }
 
diff --git a/incubator/net/src/main/java/org/onosproject/incubator/net/virtual/impl/VirtualNetworkFlowRuleManager.java b/incubator/net/src/main/java/org/onosproject/incubator/net/virtual/impl/VirtualNetworkFlowRuleManager.java
index f6c6e2b..0cbe131 100644
--- a/incubator/net/src/main/java/org/onosproject/incubator/net/virtual/impl/VirtualNetworkFlowRuleManager.java
+++ b/incubator/net/src/main/java/org/onosproject/incubator/net/virtual/impl/VirtualNetworkFlowRuleManager.java
@@ -112,7 +112,7 @@
      */
     public VirtualNetworkFlowRuleManager(VirtualNetworkService virtualNetworkManager,
                                          NetworkId networkId) {
-        super(virtualNetworkManager, networkId);
+        super(virtualNetworkManager, networkId, FlowRuleEvent.class);
 
         store = serviceDirectory.get(VirtualNetworkFlowRuleStore.class);
 
diff --git a/incubator/net/src/main/java/org/onosproject/incubator/net/virtual/impl/VirtualNetworkGroupManager.java b/incubator/net/src/main/java/org/onosproject/incubator/net/virtual/impl/VirtualNetworkGroupManager.java
index fee36bc..02fa2be 100644
--- a/incubator/net/src/main/java/org/onosproject/incubator/net/virtual/impl/VirtualNetworkGroupManager.java
+++ b/incubator/net/src/main/java/org/onosproject/incubator/net/virtual/impl/VirtualNetworkGroupManager.java
@@ -67,7 +67,7 @@
     private boolean purgeOnDisconnection = false;
 
     public VirtualNetworkGroupManager(VirtualNetworkService manager, NetworkId networkId) {
-        super(manager, networkId);
+        super(manager, networkId, GroupEvent.class);
 
         store = serviceDirectory.get(VirtualNetworkGroupStore.class);
         deviceService = manager.get(networkId, DeviceService.class);
diff --git a/incubator/net/src/main/java/org/onosproject/incubator/net/virtual/impl/VirtualNetworkHostManager.java b/incubator/net/src/main/java/org/onosproject/incubator/net/virtual/impl/VirtualNetworkHostManager.java
index 216a76b..35f915b 100644
--- a/incubator/net/src/main/java/org/onosproject/incubator/net/virtual/impl/VirtualNetworkHostManager.java
+++ b/incubator/net/src/main/java/org/onosproject/incubator/net/virtual/impl/VirtualNetworkHostManager.java
@@ -57,7 +57,7 @@
      */
     public VirtualNetworkHostManager(VirtualNetworkService virtualNetworkManager,
                                      NetworkId networkId) {
-        super(virtualNetworkManager, networkId);
+        super(virtualNetworkManager, networkId, HostEvent.class);
     }
 
 
diff --git a/incubator/net/src/main/java/org/onosproject/incubator/net/virtual/impl/VirtualNetworkIntentManager.java b/incubator/net/src/main/java/org/onosproject/incubator/net/virtual/impl/VirtualNetworkIntentManager.java
index 4026cb5..41cd952 100644
--- a/incubator/net/src/main/java/org/onosproject/incubator/net/virtual/impl/VirtualNetworkIntentManager.java
+++ b/incubator/net/src/main/java/org/onosproject/incubator/net/virtual/impl/VirtualNetworkIntentManager.java
@@ -75,7 +75,7 @@
     public VirtualNetworkIntentManager(VirtualNetworkService virtualNetworkManager,
                                        NetworkId networkId) {
 
-        super(virtualNetworkManager, networkId);
+        super(virtualNetworkManager, networkId, IntentEvent.class);
 
         this.store = serviceDirectory.get(VirtualNetworkStore.class);
         this.intentService = serviceDirectory.get(IntentService.class);
diff --git a/incubator/net/src/main/java/org/onosproject/incubator/net/virtual/impl/VirtualNetworkLinkManager.java b/incubator/net/src/main/java/org/onosproject/incubator/net/virtual/impl/VirtualNetworkLinkManager.java
index 3a93e3c..ed18f86 100644
--- a/incubator/net/src/main/java/org/onosproject/incubator/net/virtual/impl/VirtualNetworkLinkManager.java
+++ b/incubator/net/src/main/java/org/onosproject/incubator/net/virtual/impl/VirtualNetworkLinkManager.java
@@ -51,7 +51,7 @@
      */
     public VirtualNetworkLinkManager(VirtualNetworkService virtualNetworkManager,
                                      NetworkId networkId) {
-        super(virtualNetworkManager, networkId);
+        super(virtualNetworkManager, networkId, LinkEvent.class);
     }
 
     @Override
diff --git a/incubator/net/src/main/java/org/onosproject/incubator/net/virtual/impl/VirtualNetworkManager.java b/incubator/net/src/main/java/org/onosproject/incubator/net/virtual/impl/VirtualNetworkManager.java
index 11a7990..ff3c696 100644
--- a/incubator/net/src/main/java/org/onosproject/incubator/net/virtual/impl/VirtualNetworkManager.java
+++ b/incubator/net/src/main/java/org/onosproject/incubator/net/virtual/impl/VirtualNetworkManager.java
@@ -142,10 +142,10 @@
 
     @Activate
     public void activate() {
-        store.setDelegate(delegate);
         eventDispatcher.addSink(VirtualNetworkEvent.class, listenerRegistry);
         eventDispatcher.addSink(VirtualEvent.class,
                                 VirtualListenerRegistryManager.getInstance());
+        store.setDelegate(delegate);
         intentService.addListener(intentListener);
         appId = coreService.registerApplication(VIRTUAL_NETWORK_APP_ID_STRING);
         log.info("Started");
@@ -364,6 +364,7 @@
     private final Map<ServiceKey, VnetService> networkServices = Maps.newConcurrentMap();
 
     @Override
+    @SuppressWarnings("unchecked")
     public <T> T get(NetworkId networkId, Class<T> serviceClass) {
         checkNotNull(networkId, NETWORK_NULL);
         ServiceKey serviceKey = networkServiceKey(networkId, serviceClass);
@@ -453,7 +454,7 @@
          * @param networkId    network identifier
          * @param serviceClass service class
          */
-        public ServiceKey(NetworkId networkId, Class serviceClass) {
+        ServiceKey(NetworkId networkId, Class serviceClass) {
 
             checkNotNull(networkId, NETWORK_NULL);
             this.networkId = networkId;
diff --git a/incubator/net/src/main/java/org/onosproject/incubator/net/virtual/impl/VirtualNetworkTopologyManager.java b/incubator/net/src/main/java/org/onosproject/incubator/net/virtual/impl/VirtualNetworkTopologyManager.java
index c55829d..c056b25 100644
--- a/incubator/net/src/main/java/org/onosproject/incubator/net/virtual/impl/VirtualNetworkTopologyManager.java
+++ b/incubator/net/src/main/java/org/onosproject/incubator/net/virtual/impl/VirtualNetworkTopologyManager.java
@@ -68,7 +68,7 @@
      */
     public VirtualNetworkTopologyManager(VirtualNetworkService virtualNetworkManager,
                                          NetworkId networkId) {
-        super(virtualNetworkManager, networkId);
+        super(virtualNetworkManager, networkId, TopologyEvent.class);
     }
 
     @Override
