Merge "Added controller is-connected code"
[ovsdb.git] / openstack / net-virt / src / main / java / org / opendaylight / ovsdb / openstack / netvirt / api / EventDispatcher.java
1 /*
2  * Copyright (C) 2014 Red Hat, Inc.
3  *
4  * This program and the accompanying materials are made available under the
5  * terms of the Eclipse Public License v1.0 which accompanies this distribution,
6  * and is available at http://www.eclipse.org/legal/epl-v10.html
7  *
8  * Authors : Dave Tucker, Flavio Fernandes
9  */
10
11 package org.opendaylight.ovsdb.openstack.netvirt.api;
12
13 import org.opendaylight.ovsdb.openstack.netvirt.AbstractEvent;
14 import org.opendaylight.ovsdb.openstack.netvirt.AbstractHandler;
15 import org.osgi.framework.ServiceReference;
16
17 /**
18  * Openstack related events will be enqueued into a common event queue.
19  * This interface provides access to an event dispatcher, as well as registration to link dispatcher to which handlers
20  * dispatcher will utilize.
21  */
22 public interface EventDispatcher {
23     /**
24      * Enqueue the event.
25      * @param event the {@link org.opendaylight.ovsdb.openstack.netvirt.AbstractEvent} event to be handled.
26      */
27     public void enqueueEvent(AbstractEvent event);
28     public void eventHandlerAdded(final ServiceReference ref, AbstractHandler handler);
29     public void eventHandlerRemoved(final ServiceReference ref);
30 }
31