Add missing handleInterfaceDelete for tunnel case
[ovsdb.git] / openstack / net-virt / src / main / java / org / opendaylight / ovsdb / openstack / netvirt / api / OvsdbConfigurationService.java
1 package org.opendaylight.ovsdb.openstack.netvirt.api;
2
3 import java.util.List;
4 import java.util.concurrent.ConcurrentMap;
5 import java.util.concurrent.ExecutionException;
6 import org.opendaylight.ovsdb.lib.notation.Row;
7 import org.opendaylight.ovsdb.lib.notation.UUID;
8 import org.opendaylight.ovsdb.lib.schema.GenericTableSchema;
9 import org.opendaylight.ovsdb.lib.schema.typed.TypedBaseTable;
10 import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.ovsdb.rev150105.OvsdbTerminationPointAugmentation;
11 import org.opendaylight.yang.gen.v1.urn.tbd.params.xml.ns.yang.network.topology.rev131021.network.topology.topology.Node;
12
13 /**
14  * Created by shague on 4/20/15.
15  */
16 public interface OvsdbConfigurationService {
17
18     /**
19      * @deprecated This version of insertRow is a short-term replacement for the older & now deprecated method of the same name.
20      * This API assumes an Open_vSwitch database Schema.
21      *
22      * This API is replaced by
23      * {@link #insertRow(Node, String, String, String, Row < GenericTableSchema >) insertRow} and
24      * {@link #insertTree(Node, String, String, String, Row<GenericTableSchema>) insertTree}
25      *
26      * @param node OVSDB Node
27      * @param tableName Table on which the row is inserted
28      * @param parentUuid UUID of the parent table to which this operation will result in attaching/mutating.
29      * @param row Row of table Content to be inserted
30      * @return UUID of the inserted Row
31      */
32     @Deprecated
33     public StatusWithUuid insertRow(Node node, String tableName, String parentUuid, Row<GenericTableSchema> row);
34
35     /**
36      * @deprecated This version of updateRow is a short-term replacement for the older & now deprecated method of the same name.
37      * This API assumes an Open_vSwitch database Schema.
38      *
39      * This API is replaced by
40      * {@link #updateRow(Node, String, String, UUID, Row<GenericTableSchema>, boolean) updateRow}
41      *
42      * @param node OVSDB Node
43      * @param tableName Table on which the row is Updated
44      * @param parentUuid UUID of the parent row on which this operation might result in mutating.
45      * @param rowUuid UUID of the row that is being updated
46      * @param row Row of table Content to be Updated. Include just those columns that needs to be updated.
47      */
48     @Deprecated
49     public Status updateRow (Node node, String tableName, String parentUuid, String rowUuid, Row row);
50
51     /**
52      * @deprecated This version of deleteRow is a short-term replacement for the older & now deprecated method of the same name.
53      * This API assumes an Open_vSwitch database Schema.
54      *
55      * This API is replaced by {@link #deleteRow(Node, String, String, UUID) deleteRow}
56      *
57      * @param node OVSDB Node
58      * @param tableName Table on which the row is Updated
59      * @param rowUuid UUID of the row that is being deleted
60      */
61     @Deprecated
62     public Status deleteRow (Node node, String tableName, String rowUuid);
63
64     /**
65      * @deprecated This version of getRow is a short-term replacement for the older & now deprecated method of the same name.
66      * This API assumes an Open_vSwitch database Schema.
67      *
68      * This API is replaced by {@link #getRow(Node, String, String, UUID) getRow}
69      *
70      * @param node OVSDB Node
71      * @param tableName Table Name
72      * @param rowUuid UUID of the row being queried
73      * @return a row with a list of Column data that corresponds to an unique Row-identifier called uuid in a given table.
74      */
75     @Deprecated
76     public Row getRow(Node node, String tableName, String uuid);
77
78     /**
79      * Returns a Row from a table for the specified uuid.
80      *
81      * @param node OVSDB Node
82      * @param databaseName Database Name that represents the Schema supported by the node.
83      * @param tableName Table Name
84      * @param uuid UUID of the row being queried
85      * @throws OvsdbPluginException Any failure during the get operation will result in a specific exception.
86      * @return a row with a list of Column data that corresponds to an unique Row-identifier called uuid in a given table.
87      */
88     public Row<GenericTableSchema> getRow(Node node, String databaseName, String tableName, UUID uuid) throws OvsdbPluginException;
89
90     /**
91      * @Deprecated This version of getRows is a short-term replacement for the older & now deprecated method of the same name.
92      * This API assumes an Open_vSwitch database Schema.
93      *
94      * This API is replaced by
95      * {@link #getRows(Node, String, String) getRows} and {@link #getRows(Node, String, String, String) getRows}
96      *
97      * @param node OVSDB Node
98      * @param tableName Table Name
99      * @return List of rows that makes the entire Table.
100      */
101     @Deprecated
102     public ConcurrentMap<String, Row> getRows(Node node, String tableName);
103
104     /**
105      * Returns all rows of a table.
106      *
107      * @param node OVSDB Node
108      * @param databaseName Database Name that represents the Schema supported by the node.
109      * @param tableName Table Name
110      * @throws OvsdbPluginException Any failure during the get operation will result in a specific exception.
111      * @return Map of rows to its UUID that makes the entire Table.
112      */
113     public ConcurrentMap<UUID, Row<GenericTableSchema>> getRows(Node node, String databaseName, String tableName) throws OvsdbPluginException;
114
115     /**
116      * Returns all rows of a table filtered by query string.
117      *
118      * @param node OVSDB Node
119      * @param databaseName Database Name that represents the Schema supported by the node.
120      * @param tableName Table Name
121      * @param fiqlQuery FIQL style String Query {@link http://tools.ietf.org/html/draft-nottingham-atompub-fiql-00} to filter rows
122      * @throws OvsdbPluginException Any failure during the get operation will result in a specific exception.
123      * @return Map of rows to its UUID that makes the entire Table.
124      */
125     public ConcurrentMap<UUID, Row<GenericTableSchema>> getRows(Node node, String databaseName, String tableName, String fiqlQuery) throws OvsdbPluginException;
126
127     /**
128      * @Deprecated Returns all the Tables in a given Ndoe.
129      * This API assumes an Open_vSwitch database Schema.
130      *
131      * This API is replaced by
132      * {@link #getTables(Node, String) getTables}
133      * @param node OVSDB node
134      * @return List of Table Names that make up Open_vSwitch schema.
135      */
136     @Deprecated
137     public List<String> getTables(Node node);
138
139     /**
140      * setOFController is a convenience method used by existing applications to setup Openflow Controller on
141      * a Open_vSwitch Bridge.
142      * This API assumes an Open_vSwitch database Schema.
143      *
144      * @param node Node
145      * @param bridgeUUID uuid of the Bridge for which the ip-address of Openflow Controller should be programmed.
146      * @return Boolean representing success or failure of the operation.
147      *
148      * @throws InterruptedException
149      * @throws ExecutionException
150      */
151     public Boolean setOFController(Node node, String bridgeUUID) throws InterruptedException, ExecutionException;
152
153     public <T extends TypedBaseTable<?>> String getTableName(Node node, Class<T> typedClass);
154     public <T extends TypedBaseTable<?>> T getTypedRow(Node node, Class<T> typedClass, Row row);
155     public <T extends TypedBaseTable<?>> T createTypedRow(Node node, Class<T> typedClass);
156
157     public ConcurrentMap<String, OvsdbTerminationPointAugmentation> getInterfaces(Node node);
158 }