bug 8029 added ref counts for physical locators.
[ovsdb.git] / hwvtepsouthbound / hwvtepsouthbound-impl / src / main / java / org / opendaylight / ovsdb / hwvtepsouthbound / transact / TransactCommand.java
1 /*
2  * Copyright (c) 2015 Ericsson India Global Services Pvt Ltd. 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
9 package org.opendaylight.ovsdb.hwvtepsouthbound.transact;
10
11 import org.opendaylight.ovsdb.lib.operations.TransactionBuilder;
12 import org.opendaylight.yang.gen.v1.urn.tbd.params.xml.ns.yang.network.topology.rev131021.network.topology.topology.Node;
13 import org.opendaylight.yangtools.yang.binding.Identifiable;
14 import org.opendaylight.yangtools.yang.binding.InstanceIdentifier;
15
16 public interface TransactCommand<T extends Identifiable> {
17
18     void execute(TransactionBuilder transaction);
19
20     default void onConfigUpdate(TransactionBuilder transaction, InstanceIdentifier<Node> nodeIid, T data,
21                                 InstanceIdentifier key, Object... extraData) {
22     }
23
24     default void doDeviceTransaction(TransactionBuilder transaction, InstanceIdentifier<Node> nodeIid, T data,
25                                      InstanceIdentifier key, Object... extraData) {
26     }
27
28     default void onSuccess(TransactionBuilder deviceTransaction) {
29     }
30
31     default void onFailure(TransactionBuilder deviceTransaction) {
32     }
33 }