Fix ClusterSingletonServiceRegistration 53/73753/2
authorRobert Varga <robert.varga@pantheon.tech>
Wed, 4 Jul 2018 14:48:50 +0000 (16:48 +0200)
committerTom Pantelis <tompantelis@gmail.com>
Mon, 9 Jul 2018 18:54:09 +0000 (18:54 +0000)
This interface is intended to be a Registration, not an AutoCloseable,
and so is its only implementation.

Switch from AutoCloseable to ObjectRegistration, so users can take
advantage of the simplified API.

Change-Id: I47be557dce38f23e92d9744f019e327fa03c9321
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
singleton-service/mdsal-singleton-common-api/src/main/java/org/opendaylight/mdsal/singleton/common/api/ClusterSingletonServiceRegistration.java

index 831c1852319b5bf1411acae8456c6529bda81b38..8b689335bebc23be727923144019c662637b4fe9 100644 (file)
@@ -5,17 +5,13 @@
  * terms of the Eclipse Public License v1.0 which accompanies this distribution,
  * and is available at http://www.eclipse.org/legal/epl-v10.html
  */
-
 package org.opendaylight.mdsal.singleton.common.api;
 
+import org.opendaylight.yangtools.concepts.ObjectRegistration;
+
 /**
- * {@link ClusterSingletonServiceRegistration} interface contains a marker for
- * holding ClusterSingletonService registration and posibility to close it
- * via {@link AutoCloseable} interface.
+ * An {@link ObjectRegistration} of a {@link ClusterSingletonService} instance.
  */
-public interface ClusterSingletonServiceRegistration extends AutoCloseable {
+public interface ClusterSingletonServiceRegistration extends ObjectRegistration<ClusterSingletonService> {
 
-    /**
-     * Empty body for mark a ClusterSingletonService Registration instance
-     */
 }