2 * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
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
8 package org.opendaylight.controller.messagebus.spi;
10 import java.util.List;
11 import org.opendaylight.yang.gen.v1.urn.cisco.params.xml.ns.yang.messagebus.eventsource.rev141202.EventSourceService;
12 import org.opendaylight.yang.gen.v1.urn.tbd.params.xml.ns.yang.network.topology.rev131021.network.topology.topology.NodeKey;
13 import org.opendaylight.yangtools.yang.model.api.SchemaPath;
16 * Event source is a node in topology which is able to produce notifications.
17 * To register event source you use {@link EventSourceRegistry#registerEventSource(EventSource)}.
18 * EventSourceRegistry will request registered event source to publish notifications
19 * whenever EventSourceRegistry has been asked to publish a certain type of notifications.
20 * EventSourceRegistry will call method JoinTopic to request EventSource to publish notification.
21 * Event source must implement method JoinTopic (from superinterface {@link EventSourceService}).
24 public interface EventSource extends EventSourceService, AutoCloseable {
27 * Identifier of node associated with event source.
29 * @return instance of NodeKey
31 NodeKey getSourceNodeKey();
34 * List the types of notifications which source can produce.
36 * @return list of available notification
38 List<SchemaPath> getAvailableNotifications();