Package: DeviceConfigurationStoreServiceDummy
DeviceConfigurationStoreServiceDummy
name | instruction | branch | complexity | line | method | ||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
DeviceConfigurationStoreServiceDummy() |
|
|
|
|
|
||||||||||||||||||||
getApplicationSettings(KapuaId, KapuaId) |
|
|
|
|
|
||||||||||||||||||||
getConfigMetadata(KapuaId) |
|
|
|
|
|
||||||||||||||||||||
getConfigValues(KapuaId) |
|
|
|
|
|
||||||||||||||||||||
getConfigurations(KapuaId, KapuaId) |
|
|
|
|
|
||||||||||||||||||||
getConfigurations(KapuaId, KapuaId, String) |
|
|
|
|
|
||||||||||||||||||||
isApplicationEnabled(KapuaId, KapuaId) |
|
|
|
|
|
||||||||||||||||||||
isServiceEnabled(KapuaId) |
|
|
|
|
|
||||||||||||||||||||
setApplicationSettings(KapuaId, KapuaId, DeviceConfigurationStoreSettings) |
|
|
|
|
|
||||||||||||||||||||
setConfigValues(KapuaId, KapuaId, Map) |
|
|
|
|
|
||||||||||||||||||||
storeConfigurations(KapuaId, KapuaId, DeviceComponentConfiguration) |
|
|
|
|
|
||||||||||||||||||||
storeConfigurations(KapuaId, KapuaId, DeviceConfiguration) |
|
|
|
|
|
Coverage
1: /*******************************************************************************
2: * Copyright (c) 2022 Eurotech and/or its affiliates and others
3: *
4: * This program and the accompanying materials are made
5: * available under the terms of the Eclipse Public License 2.0
6: * which is available at https://www.eclipse.org/legal/epl-2.0/
7: *
8: * SPDX-License-Identifier: EPL-2.0
9: *
10: * Contributors:
11: * Eurotech - initial API and implementation
12: *******************************************************************************/
13: package org.eclipse.kapua.service.device.management.configuration.store.dummy;
14:
15: import org.eclipse.kapua.locator.KapuaProvider;
16: import org.eclipse.kapua.commons.configuration.metatype.EmptyTocd;
17: import org.eclipse.kapua.commons.service.internal.KapuaServiceDisabledException;
18: import org.eclipse.kapua.model.config.metatype.KapuaTocd;
19: import org.eclipse.kapua.model.id.KapuaId;
20: import org.eclipse.kapua.service.device.management.configuration.DeviceComponentConfiguration;
21: import org.eclipse.kapua.service.device.management.configuration.DeviceConfiguration;
22: import org.eclipse.kapua.service.device.management.configuration.store.DeviceConfigurationStoreService;
23: import org.eclipse.kapua.service.device.management.configuration.store.settings.DeviceConfigurationStoreSettings;
24:
25: import java.util.Map;
26:
27: /**
28: * {@link DeviceConfigurationStoreService} dummy implementation.
29: *
30: * @since 2.0.0
31: */
32: @KapuaProvider
33: public class DeviceConfigurationStoreServiceDummy implements DeviceConfigurationStoreService {
34:
35: @Override
36: public DeviceComponentConfiguration getConfigurations(KapuaId scopeId, KapuaId deviceId, String configurationComponentPid) throws KapuaServiceDisabledException {
37: throw new KapuaServiceDisabledException(this.getClass().getName());
38: }
39:
40: @Override
41: public DeviceConfiguration getConfigurations(KapuaId scopeId, KapuaId deviceId) throws KapuaServiceDisabledException {
42: throw new KapuaServiceDisabledException(this.getClass().getName());
43: }
44:
45: @Override
46: public void storeConfigurations(KapuaId scopeId, KapuaId deviceId, DeviceComponentConfiguration deviceComponentConfiguration) throws KapuaServiceDisabledException {
47: throw new KapuaServiceDisabledException(this.getClass().getName());
48: }
49:
50: @Override
51: public void storeConfigurations(KapuaId scopeId, KapuaId deviceId, DeviceConfiguration deviceConfiguration) throws KapuaServiceDisabledException {
52: throw new KapuaServiceDisabledException(this.getClass().getName());
53: }
54:
55: @Override
56: public KapuaTocd getConfigMetadata(KapuaId scopeId) {
57: return new EmptyTocd();
58: }
59:
60: @Override
61: public Map<String, Object> getConfigValues(KapuaId scopeId) {
62: return null;
63: }
64:
65: @Override
66: public void setConfigValues(KapuaId scopeId, KapuaId parentId, Map<String, Object> values) {
67: }
68:
69: @Override
70: public DeviceConfigurationStoreSettings getApplicationSettings(KapuaId scopeId, KapuaId deviceId) throws KapuaServiceDisabledException {
71: throw new KapuaServiceDisabledException(this.getClass().getName());
72: }
73:
74: @Override
75: public void setApplicationSettings(KapuaId scopeId, KapuaId deviceId, DeviceConfigurationStoreSettings deviceApplicationSettings) throws KapuaServiceDisabledException {
76: throw new KapuaServiceDisabledException(this.getClass().getName());
77: }
78:
79: @Override
80: public boolean isServiceEnabled(KapuaId scopeId) {
81: return false;
82: }
83:
84: @Override
85: public boolean isApplicationEnabled(KapuaId scopeId, KapuaId deviceId) {
86: return false;
87: }
88: }