]> git.basschouten.com Git - openhab-addons.git/blob
59033262a16d67ed4931769e6e1d9376b745034c
[openhab-addons.git] /
1 /**
2  * Copyright (c) 2010-2023 Contributors to the openHAB project
3  *
4  * See the NOTICE file(s) distributed with this work for additional
5  * information.
6  *
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
10  *
11  * SPDX-License-Identifier: EPL-2.0
12  */
13 package org.openhab.binding.solaredge.internal.model;
14
15 import java.util.List;
16
17 import org.eclipse.jdt.annotation.NonNullByDefault;
18 import org.eclipse.jdt.annotation.Nullable;
19
20 /**
21  * this class is used to map the aggregate data response of the public API
22  *
23  * @author Alexander Friese - initial contribution
24  */
25 @NonNullByDefault
26 public class AggregateDataResponsePublicApi {
27
28     public static class MeterTelemetry {
29         public @Nullable String date;
30         public @Nullable Double value;
31     }
32
33     public static class MeterTelemetries {
34         public @Nullable String type;
35         public @Nullable List<MeterTelemetry> values;
36     }
37
38     public static class EnergyDetails {
39         public @Nullable AggregatePeriod timeUnit;
40         public @Nullable String unit;
41         public @Nullable List<MeterTelemetries> meters;
42     }
43
44     private @Nullable EnergyDetails energyDetails;
45
46     public @Nullable EnergyDetails getEnergyDetails() {
47         return energyDetails;
48     }
49
50     public void setEnergyDetails(EnergyDetails energyDetails) {
51         this.energyDetails = energyDetails;
52     }
53 }