X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=blobdiff_plain;ds=sidebyside;f=binding2%2Fmdsal-binding2-api%2Fsrc%2Fmain%2Fjava%2Forg%2Fopendaylight%2Fmdsal%2Fbinding%2Fjavav2%2Fapi%2FCursorAwareWriteTransaction.java;fp=binding2%2Fmdsal-binding2-api%2Fsrc%2Fmain%2Fjava%2Forg%2Fopendaylight%2Fmdsal%2Fbinding%2Fjavav2%2Fapi%2FCursorAwareWriteTransaction.java;h=0000000000000000000000000000000000000000;hb=c9ced06c906691b0c58f9173fc06400cc565f106;hp=bdf4268da5a304a93995e13b4938cef0d789ec0c;hpb=b020023b71447f7fd2eee3c1eb4108578346da6d;p=mdsal.git diff --git a/binding2/mdsal-binding2-api/src/main/java/org/opendaylight/mdsal/binding/javav2/api/CursorAwareWriteTransaction.java b/binding2/mdsal-binding2-api/src/main/java/org/opendaylight/mdsal/binding/javav2/api/CursorAwareWriteTransaction.java deleted file mode 100644 index bdf4268da5..0000000000 --- a/binding2/mdsal-binding2-api/src/main/java/org/opendaylight/mdsal/binding/javav2/api/CursorAwareWriteTransaction.java +++ /dev/null @@ -1,75 +0,0 @@ -/* - * Copyright (c) 2017 Pantheon Technologies s.r.o. and others. All rights reserved. - * - * This program and the accompanying materials are made available under the - * 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.binding.javav2.api; - -import com.google.common.annotations.Beta; -import java.util.function.BiConsumer; -import javax.annotation.Nonnull; -import javax.annotation.Nullable; -import org.opendaylight.mdsal.binding.javav2.spec.base.TreeNode; -import org.opendaylight.mdsal.common.api.TransactionCommitFailedException; - -/** - * Write transaction that provides cursor's with write access to the data tree. - */ -@Beta -public interface CursorAwareWriteTransaction extends DataTreeCursorProvider { - - /** - * Create a {@link DataTreeWriteCursor} anchored at the specified path. - * There can only be one cursor open at a time. - * - *

- * @param path Path at which the cursor is to be anchored - * @return write cursor at the desired location. - * @throws IllegalStateException when there's an open cursor, or this transaction is closed already. - */ - @Nullable - @Override - DataTreeCursor createCursor(@Nonnull DataTreeIdentifier path); - - /** - * Cancels the transaction. - * - *

- * Transactions can only be cancelled if it was not yet submited. - * - *

- * Invoking cancel() on failed or already canceled will have no effect, and transaction is - * considered cancelled. - * - *

- * Invoking cancel() on finished transaction (future returned by {@link #submit(BiConsumer)} already - * successfully completed) will always fail (return false). - * - * @return false if the task could not be cancelled, typically because it has already - * completed normally; true otherwise - * - */ - boolean cancel(); - - /** - * Submits this transaction to be asynchronously applied to update the logical data tree. Callback - * conveys the result of applying the data changes. - * - *

- * This call logically seals the transaction, which prevents the client from further changing - * data tree using this transaction's cursor. Any subsequent calls to - * createCursorCursor(DOMDataTreeIdentifier - * or any of the cursor's methods will fail with {@link IllegalStateException}. - * - *

- * The transaction is marked as submitted and enqueued into the shard back-end for - * processing. - * - * @param callback result callback - * @param result type - */ - void submit(BiConsumer callback); -} \ No newline at end of file