Use DataTreeChangeListener instead of DataChangeListener
[ovsdb.git] / southbound / southbound-impl / src / main / java / org / opendaylight / ovsdb / southbound / ovsdb / transact / TransactInvoker.java
1 /*
2  * Copyright (c) 2014, 2016 Cisco Systems, Inc. and others.  All rights reserved.
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 package org.opendaylight.ovsdb.southbound.ovsdb.transact;
9
10 import java.util.Collection;
11
12 import org.opendaylight.controller.md.sal.binding.api.DataTreeModification;
13 import org.opendaylight.controller.md.sal.common.api.data.AsyncDataChangeEvent;
14 import org.opendaylight.yang.gen.v1.urn.tbd.params.xml.ns.yang.network.topology.rev131021.network.topology.topology.Node;
15 import org.opendaylight.yangtools.yang.binding.DataObject;
16 import org.opendaylight.yangtools.yang.binding.InstanceIdentifier;
17
18 /**
19  * Contract for a transactional invoker.
20  */
21 public interface TransactInvoker {
22     /**
23      * Invoke the given transactional command, with the given bridge state, on the given events.
24      *
25      * @param command The transactional command.
26      * @param state The bridge state.
27      * @param events The events to be processed.
28      */
29     void invoke(TransactCommand command, BridgeOperationalState state,
30                 AsyncDataChangeEvent<InstanceIdentifier<?>, DataObject> events);
31
32     /**
33      * Invoke the given transactional command, with the given bridge state, on the given modifications.
34      *
35      * @param command The transactional command.
36      * @param state The bridge state.
37      * @param modifications The modifications to be processed.
38      */
39     void invoke(TransactCommand command, BridgeOperationalState state,
40                 Collection<DataTreeModification<Node>> modifications);
41 }