Avantika-Huawei | 9e848e8 | 2016-09-01 12:12:42 +0530 | [diff] [blame] | 1 | /* |
Brian O'Connor | 0a4e674 | 2016-09-15 23:03:10 -0700 | [diff] [blame] | 2 | * Copyright 2016-present Open Networking Laboratory |
Avantika-Huawei | 9e848e8 | 2016-09-01 12:12:42 +0530 | [diff] [blame] | 3 | * |
| 4 | * Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | * you may not use this file except in compliance with the License. |
| 6 | * You may obtain a copy of the License at |
| 7 | * |
| 8 | * http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | * |
| 10 | * Unless required by applicable law or agreed to in writing, software |
| 11 | * distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | * See the License for the specific language governing permissions and |
| 14 | * limitations under the License. |
| 15 | */ |
| 16 | package org.onosproject.pcelabelstore.util; |
| 17 | |
| 18 | import org.onosproject.store.service.AtomicCounterBuilder; |
| 19 | import org.onosproject.store.service.AtomicValueBuilder; |
| 20 | import org.onosproject.store.service.ConsistentMapBuilder; |
| 21 | import org.onosproject.store.service.DistributedSetBuilder; |
| 22 | import org.onosproject.store.service.EventuallyConsistentMapBuilder; |
| 23 | import org.onosproject.store.service.TransactionContextBuilder; |
| 24 | |
| 25 | public class TestStorageService extends StorageServiceAdapter { |
| 26 | |
| 27 | |
| 28 | @Override |
| 29 | public <K, V> EventuallyConsistentMapBuilder<K, V> eventuallyConsistentMapBuilder() { |
| 30 | return TestEventuallyConsistentMap.builder(); |
| 31 | } |
| 32 | |
| 33 | @Override |
| 34 | public <K, V> ConsistentMapBuilder<K, V> consistentMapBuilder() { |
| 35 | return TestConsistentMap.builder(); |
| 36 | } |
| 37 | |
| 38 | @Override |
| 39 | public <E> DistributedSetBuilder<E> setBuilder() { |
| 40 | return TestDistributedSet.builder(); |
| 41 | } |
| 42 | |
| 43 | @Override |
| 44 | public AtomicCounterBuilder atomicCounterBuilder() { |
| 45 | return TestAtomicCounter.builder(); |
| 46 | } |
| 47 | |
| 48 | @Override |
| 49 | public <V> AtomicValueBuilder<V> atomicValueBuilder() { |
| 50 | throw new UnsupportedOperationException("atomicValueBuilder"); |
| 51 | } |
| 52 | |
| 53 | @Override |
| 54 | public TransactionContextBuilder transactionContextBuilder() { |
| 55 | throw new UnsupportedOperationException("transactionContextBuilder"); |
| 56 | } |
| 57 | } |