X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?p=controller.git;a=blobdiff_plain;f=opendaylight%2Fmd-sal%2Fsal-binding-api%2Fsrc%2Fmain%2Fjava%2Forg%2Fopendaylight%2Fcontroller%2Fsal%2Fbinding%2Fapi%2Fdata%2FDataModificationTransaction.java;h=0c250fdbee4c2454d0d9c1afa981ef71b4c05acc;hp=9ce11c71e4b6d1a41fa61a4dfa94401700db97e1;hb=c46e223995956f1f759c551163c212947c1e2fb7;hpb=a3dbf5335c352c7463674e31314ce2b5285cb6fe diff --git a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/data/DataModificationTransaction.java b/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/data/DataModificationTransaction.java index 9ce11c71e4..0c250fdbee 100644 --- a/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/data/DataModificationTransaction.java +++ b/opendaylight/md-sal/sal-binding-api/src/main/java/org/opendaylight/controller/sal/binding/api/data/DataModificationTransaction.java @@ -13,38 +13,48 @@ import java.util.concurrent.Future; import org.opendaylight.controller.md.sal.common.api.TransactionStatus; import org.opendaylight.controller.md.sal.common.api.data.DataModification; import org.opendaylight.yangtools.concepts.ListenerRegistration; -import org.opendaylight.yangtools.concepts.Registration; import org.opendaylight.yangtools.yang.binding.DataObject; import org.opendaylight.yangtools.yang.binding.InstanceIdentifier; import org.opendaylight.yangtools.yang.common.RpcResult; +/** + * + * + * @deprecated Replaced by more specific transaction types. Please use + * {@link org.opendaylight.controller.md.sal.binding.api.DataBroker#newReadOnlyTransaction(), + * {@link org.opendaylight.controller.md.sal.binding.api.DataBroker#newReadWriteTransaction() + * or + * {@link org.opendaylight.controller.md.sal.binding.api.DataBroker#newWriteOnlyTransaction(). + * + * + */ +@Deprecated public interface DataModificationTransaction extends DataModification, DataObject> { - /** * Returns an unique identifier for transaction - * + * */ @Override - public Object getIdentifier(); - + Object getIdentifier(); + /** * Initiates a two-phase commit of candidate data. - * + * *

* The {@link Consumer} could initiate a commit of candidate data - * + * *

* The successful commit changes the state of the system and may affect * several components. - * + * *

* The effects of successful commit of data are described in the * specifications and YANG models describing the {@link Provider} components * of controller. It is assumed that {@link Consumer} has an understanding * of this changes. - * - * - * @see DataCommitHandler for further information how two-phase commit is + * + * + * @see org.opendaylight.controller.md.sal.common.api.data.DataCommitHandler for further information how two-phase commit is * processed. * @param store * Identifier of the store, where commit should occur. @@ -52,29 +62,23 @@ public interface DataModificationTransaction extends DataModification> commit(); - - - + Future> commit(); + /** * Register a listener for transaction - * + * * @param listener * @return */ ListenerRegistration registerListener(DataTransactionListener listener); - - /** * Listener for transaction state changes - * - * */ public interface DataTransactionListener extends EventListener { /** * Callback is invoked after each transaction status change. - * + * * @param transaction Transaction * @param status New status */