Skip to content

Package: DeviceManagementApplicationDisabledException

DeviceManagementApplicationDisabledException

nameinstructionbranchcomplexitylinemethod
DeviceManagementApplicationDisabledException(String)
M: 7 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 3 C: 0
0%
M: 1 C: 0
0%
getApplicationName()
M: 3 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 1 C: 0
0%
M: 1 C: 0
0%

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.exception;
14:
15: import org.eclipse.kapua.service.device.registry.Device;
16:
17: import javax.validation.constraints.NotNull;
18:
19: /**
20: * {@link DeviceManagementException} to {@code throw} when a Device Management Application is disabled for a {@link Device}
21: *
22: * @since 2.0.0
23: */
24: public class DeviceManagementApplicationDisabledException extends DeviceManagementException {
25:
26: private static final long serialVersionUID = 7480204887766596656L;
27:
28: private final String applicationName;
29:
30: /**
31: * Constructor.
32: *
33: * @param applicationName The disabled Device Management Application.
34: * @since 2.0.0
35: */
36: public DeviceManagementApplicationDisabledException(@NotNull String applicationName) {
37: super(DeviceManagementErrorCodes.APPLICATION_DISABLED);
38:
39: this.applicationName = applicationName;
40: }
41:
42: /**
43: * Gets the disabled Device Management Application.
44: *
45: * @return The disabled Device Management Application.
46: * @since 2.0.0
47: */
48: public String getApplicationName() {
49: return applicationName;
50: }
51: }