Deprecate all MD-SAL APIs
[controller.git] / opendaylight / md-sal / sal-dom-spi / src / main / java / org / opendaylight / controller / sal / core / spi / data / DOMStoreTransactionFactory.java
1 /*
2  * Copyright (c) 2014 Cisco Systems, Inc. and others.  All rights reserved.
3  *
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
7  */
8 package org.opendaylight.controller.sal.core.spi.data;
9
10 /**
11  * Factory for DOM Store Transactions
12  *
13  * <p>
14  * Factory provides method to construct read-only, read-write and write-only
15  * transactions, which may be used to retrieve and modify stored information in
16  * Underlying {@link DOMStore} or {@link DOMStoreTransactionChain}.
17  *
18  * <p>
19  * See DOMStore, DOMStoreTransactionChain for concrete variations of this factory.
20  *
21  * <p>
22  * <b>Note:</b> This interface is used only to define common functionality
23  * between {@link DOMStore} and {@link DOMStoreTransactionChain}, which
24  * further specify behaviour of returned transactions.
25  *
26  * @deprecated Use {@link org.opendaylight.mdsal.dom.spi.store.DOMStoreTransactionFactory} instead.
27  */
28 @Deprecated
29 public interface DOMStoreTransactionFactory {
30
31     /**
32      * Creates a read only transaction.
33      *
34      * <p>
35      * Creates a new read-only transaction, which provides read access to
36      * snapshot of current state.
37      *
38      * @see DOMStoreReadTransaction for more information.
39      * @return new {@link DOMStoreReadTransaction}
40      * @throws IllegalStateException
41      *             If state of factory prevents allocating new transaction.
42      *
43      */
44     DOMStoreReadTransaction newReadOnlyTransaction();
45
46     /**
47      * Creates write only transaction.
48      *
49      * @see DOMStoreWriteTransaction for more information.
50      * @return new {@link DOMStoreWriteTransaction}
51      * @throws IllegalStateException If state of factory prevents allocating new transaction.
52      */
53     DOMStoreWriteTransaction newWriteOnlyTransaction();
54
55     /**
56      * Creates Read-Write transaction.
57      *
58      * @see DOMStoreReadWriteTransaction for more information.
59      * @return  new {@link DOMStoreWriteTransaction}
60      * @throws IllegalStateException If state of factory prevents allocating new transaction.
61      */
62     DOMStoreReadWriteTransaction newReadWriteTransaction();
63
64 }

©2013 OpenDaylight, A Linux Foundation Collaborative Project. All Rights Reserved.
OpenDaylight is a registered trademark of The OpenDaylight Project, Inc.
Linux Foundation and OpenDaylight are registered trademarks of the Linux Foundation.
Linux is a registered trademark of Linus Torvalds.