2 * Copyright (c) 2010-2023 Contributors to the openHAB project
4 * See the NOTICE file(s) distributed with this work for additional
7 * This program and the accompanying materials are made available under the
8 * terms of the Eclipse Public License 2.0 which is available at
9 * http://www.eclipse.org/legal/epl-2.0
11 * SPDX-License-Identifier: EPL-2.0
13 package org.openhab.binding.digitalstrom.internal.lib.structure.devices.deviceparameters;
15 import java.util.Date;
17 import org.openhab.binding.digitalstrom.internal.lib.structure.devices.deviceparameters.constants.MeteringTypeEnum;
18 import org.openhab.binding.digitalstrom.internal.lib.structure.devices.deviceparameters.constants.MeteringUnitsEnum;
19 import org.openhab.binding.digitalstrom.internal.lib.structure.devices.deviceparameters.impl.DSID;
20 import org.openhab.binding.digitalstrom.internal.lib.structure.devices.deviceparameters.impl.DSUID;
23 * The {@link CachedMeteringValue} saves the metering value of a digitalSTROM-Circuit.
25 * @author Alexander Betker - Initial contribution
26 * @author Michael Ochel - add methods getDateAsDate(), getMeteringType() and getMeteringUnit(); add missing java-doc
27 * @author Matthias Siegele - add methods getDateAsDate(), getMeteringType() and getMeteringUnit(); add missing java-doc
29 public interface CachedMeteringValue {
32 * Returns the {@link DSID} of the digitalSTROM-Circuit.
34 * @return dSID of circuit
36 @Deprecated(since = "value removed in API since dss v1.19.2")
40 * Returns the {@link DSUID} of the digitalSTROM-Circuit.
42 * @return dSUID of circuit
47 * Returns the saved sensor value.
49 * @return sensor value
54 * Returns the timestamp when the sensor value was read out as {@link String}.
56 * @return read out timestamp
61 * Returns the timestamp when the sensor value was read out as {@link Date}.
63 * @return read out timestamp
68 * Returns the {@link MeteringTypeEnum} of this {@link CachedMeteringValue}.
70 * @return metering type as {@link MeteringTypeEnum}
72 MeteringTypeEnum getMeteringType();
75 * Returns the {@link MeteringUnitsEnum} of this {@link CachedMeteringValue}.
77 * @return metering unit as {@link MeteringUnitsEnum}
79 MeteringUnitsEnum getMeteringUnit();