[SDFAB-359] Allow purging flows, groups and meters by device and application ID
Change-Id: I5e507d230789979ac997dbc99697fa0483363f70
(cherry picked from commit cfd774018c0ed926873b1e171c106217cb2ac568)
diff --git a/core/api/src/main/java/org/onosproject/net/meter/MeterService.java b/core/api/src/main/java/org/onosproject/net/meter/MeterService.java
index cf99b5e..6339101 100644
--- a/core/api/src/main/java/org/onosproject/net/meter/MeterService.java
+++ b/core/api/src/main/java/org/onosproject/net/meter/MeterService.java
@@ -15,6 +15,7 @@
*/
package org.onosproject.net.meter;
+import org.onosproject.core.ApplicationId;
import org.onosproject.event.ListenerService;
import org.onosproject.net.DeviceId;
@@ -93,8 +94,18 @@
* Purges all the meters on the specified device.
* @param deviceId device identifier
*/
- default void purgeMeters(DeviceId deviceId){
+ default void purgeMeters(DeviceId deviceId) {
//Default implementation does nothing
}
+ /**
+ * Purges all the meters on the given device and for the given application.
+ *
+ * @param deviceId device identifier
+ * @param appId application identifier
+ */
+ default void purgeMeters(DeviceId deviceId, ApplicationId appId) {
+ throw new UnsupportedOperationException("purgeMeter not implemented");
+ }
+
}