2 * Copyright (c) 2016 Cisco Systems, Inc. and others. All rights reserved.
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
8 package org.opendaylight.mdsal.binding.api;
10 import org.eclipse.jdt.annotation.NonNull;
11 import org.opendaylight.yangtools.concepts.ObjectRegistration;
12 import org.opendaylight.yangtools.yang.binding.DataObject;
15 * Commit Cohort registry.
18 * See {@link DataTreeCommitCohort} for more details.
20 * @author Tony Tkacik <ttkacik@cisco.com>
22 public interface DataTreeCommitCohortRegistry {
24 * Register commit cohort which will participate in three-phase commit protocols of write
25 * transaction in data broker associated with this instance of extension.
27 * @param subtree Subtree path on which commit cohort operates.
28 * @param cohort Commit cohort
29 * @return Registaration object for DOM Data Three Commit cohort.
31 <D extends DataObject, T extends DataTreeCommitCohort<D>> @NonNull ObjectRegistration<T> registerCommitCohort(
32 @NonNull DataTreeIdentifier<D> subtree, @NonNull T cohort);