Skip to contentPackage: DeviceAssetManagementService
DeviceAssetManagementService
Coverage
1: /*******************************************************************************
2: * Copyright (c) 2017, 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.asset;
14:
15: import org.eclipse.kapua.KapuaException;
16: import org.eclipse.kapua.model.id.KapuaId;
17: import org.eclipse.kapua.service.KapuaService;
18: import org.eclipse.kapua.service.device.management.DeviceManagementService;
19:
20: /**
21: * {@link DeviceAsset} {@link KapuaService} definition.
22: *
23: * @see org.eclipse.kapua.service.KapuaService
24: * @since 1.0.0
25: */
26: public interface DeviceAssetManagementService extends DeviceManagementService {
27:
28: /**
29: * Gets the {@link DeviceAssets} for the given Device.
30: *
31: * @param scopeId The target scope id
32: * @param deviceId The target {@link org.eclipse.kapua.service.device.registry.Device} id
33: * @param deviceAssets The {@link DeviceAssets} to filter read channel meta-meta
34: * @param timeout The timeout waiting for the Device response
35: * @return The {@link DeviceAssets} meta-data read
36: * @throws KapuaException
37: * @since 1.0.0
38: */
39: DeviceAssets get(KapuaId scopeId, KapuaId deviceId, DeviceAssets deviceAssets, Long timeout) throws KapuaException;
40:
41: /**
42: * Reads current values from the device channels
43: *
44: * @param scopeId The target scope id
45: * @param deviceId The target device id
46: * @param deviceAssets The {@link DeviceAssets} to filter read channel values
47: * @param timeout The timeout waiting for the Device response.
48: * @return The {@link DeviceAssets} read from the device.
49: * @throws KapuaException
50: * @since 1.0.0
51: */
52: DeviceAssets read(KapuaId scopeId, KapuaId deviceId, DeviceAssets deviceAssets, Long timeout) throws KapuaException;
53:
54: /**
55: * Writes values to the device channels
56: *
57: * @param scopeId The target scope id
58: * @param deviceId The target device id
59: * @param deviceAssets The {@link DeviceAssets} to write
60: * @param timeout The timeout waiting for the Device response.
61: * @return The {@link DeviceAssets} read after the write.
62: * @throws KapuaException
63: * @since 1.0.0
64: */
65: DeviceAssets write(KapuaId scopeId, KapuaId deviceId, DeviceAssets deviceAssets, Long timeout) throws KapuaException;
66: }