Thomas Vachuska | 6d697f1 | 2015-03-08 20:59:50 -0700 | [diff] [blame] | 1 | /* |
Brian O'Connor | a09fe5b | 2017-08-03 21:12:30 -0700 | [diff] [blame] | 2 | * Copyright 2015-present Open Networking Foundation |
Thomas Vachuska | 6d697f1 | 2015-03-08 20:59:50 -0700 | [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.cfg; |
| 17 | |
| 18 | import java.util.Set; |
| 19 | |
Ray Milkey | 911c519 | 2015-09-30 10:56:43 -0700 | [diff] [blame] | 20 | import com.google.common.collect.ImmutableSet; |
| 21 | |
Thomas Vachuska | 6d697f1 | 2015-03-08 20:59:50 -0700 | [diff] [blame] | 22 | /** |
| 23 | * Adapter for testing against component configuration service. |
| 24 | */ |
| 25 | public class ComponentConfigAdapter implements ComponentConfigService { |
Ray Milkey | 911c519 | 2015-09-30 10:56:43 -0700 | [diff] [blame] | 26 | |
Thomas Vachuska | 6d697f1 | 2015-03-08 20:59:50 -0700 | [diff] [blame] | 27 | @Override |
| 28 | public Set<String> getComponentNames() { |
| 29 | return null; |
| 30 | } |
| 31 | |
| 32 | @Override |
| 33 | public void registerProperties(Class<?> componentClass) { |
| 34 | |
| 35 | } |
| 36 | |
| 37 | @Override |
| 38 | public void unregisterProperties(Class<?> componentClass, boolean clear) { |
| 39 | |
| 40 | } |
| 41 | |
| 42 | @Override |
| 43 | public Set<ConfigProperty> getProperties(String componentName) { |
Ray Milkey | 911c519 | 2015-09-30 10:56:43 -0700 | [diff] [blame] | 44 | return ImmutableSet.of(); |
Thomas Vachuska | 6d697f1 | 2015-03-08 20:59:50 -0700 | [diff] [blame] | 45 | } |
| 46 | |
| 47 | @Override |
| 48 | public void setProperty(String componentName, String name, String value) { |
| 49 | |
| 50 | } |
| 51 | |
| 52 | @Override |
andrea | dd106a6 | 2015-10-02 13:39:48 -0700 | [diff] [blame] | 53 | public void preSetProperty(String componentName, String name, String value) { |
| 54 | } |
| 55 | |
| 56 | @Override |
Charles Chan | 8b488de | 2019-04-10 17:12:20 -0700 | [diff] [blame] | 57 | public void preSetProperty(String componentName, String name, String value, boolean override) { |
| 58 | } |
| 59 | |
| 60 | @Override |
Thomas Vachuska | 6d697f1 | 2015-03-08 20:59:50 -0700 | [diff] [blame] | 61 | public void unsetProperty(String componentName, String name) { |
| 62 | |
| 63 | } |
psneha | f31ac6f | 2018-08-02 01:16:46 -0400 | [diff] [blame] | 64 | |
| 65 | @Override |
| 66 | public ConfigProperty getProperty(String componentName, String attribute) { |
| 67 | return null; |
| 68 | } |
Thomas Vachuska | 6d697f1 | 2015-03-08 20:59:50 -0700 | [diff] [blame] | 69 | } |