*/
package org.opendaylight.controller.cluster.datastore.entityownership;
-import org.opendaylight.controller.md.sal.common.api.clustering.Entity;
-import org.opendaylight.controller.md.sal.common.api.clustering.EntityOwnershipCandidate;
-import org.opendaylight.controller.md.sal.common.impl.clustering.AbstractEntityOwnershipCandidateRegistration;
+import org.opendaylight.mdsal.eos.dom.api.DOMEntity;
+import org.opendaylight.mdsal.eos.dom.api.DOMEntityOwnershipCandidateRegistration;
+import org.opendaylight.yangtools.concepts.AbstractObjectRegistration;
/**
* Implementation of EntityOwnershipCandidateRegistration.
*
* @author Thomas Pantelis
*/
-class DistributedEntityOwnershipCandidateRegistration extends AbstractEntityOwnershipCandidateRegistration {
+class DistributedEntityOwnershipCandidateRegistration extends AbstractObjectRegistration<DOMEntity>
+ implements DOMEntityOwnershipCandidateRegistration {
private final DistributedEntityOwnershipService service;
- DistributedEntityOwnershipCandidateRegistration(EntityOwnershipCandidate candidate, Entity entity,
- DistributedEntityOwnershipService service) {
- super(candidate, entity);
+ DistributedEntityOwnershipCandidateRegistration(final DOMEntity entity,
+ final DistributedEntityOwnershipService service) {
+ super(entity);
this.service = service;
}
@Override
protected void removeRegistration() {
- service.unregisterCandidate(getEntity(), getInstance());
+ service.unregisterCandidate(getInstance());
}
-
- @Override
- public String toString() {
- return "DistributedEntityOwnershipCandidateRegistration [entity=" + getEntity() + ", candidate="
- + getInstance() + "]";
- }
-
-
}