]> git.basschouten.com Git - openhab-addons.git/blob
63687b6eea11f970070d1bab212f32c779d633bf
[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.netatmo.internal.api.dto;
14
15 import org.eclipse.jdt.annotation.NonNullByDefault;
16 import org.eclipse.jdt.annotation.Nullable;
17
18 import com.google.gson.annotations.SerializedName;
19
20 /**
21  * The {@link NAObject} class is the base class for all objects
22  * returned by the Netatmo API.
23  *
24  * @author GaĆ«l L'hopital - Initial contribution
25  *
26  */
27 @NonNullByDefault
28 public class NAObject {
29     @SerializedName(value = "id", alternate = { "program_id", "_id", "event_id" })
30     protected String id = "";
31     @SerializedName(value = "name", alternate = { "module_name", "station_name", "pseudo", "message", "key" })
32     protected @Nullable String description;
33     private boolean ignoredForThingUpdate;
34
35     public String getId() {
36         return id;
37     }
38
39     public @Nullable String getName() {
40         return description;
41     }
42
43     public boolean isIgnoredForThingUpdate() {
44         return ignoredForThingUpdate;
45     }
46
47     public void setIgnoredForThingUpdate(boolean ignoredForThingUpdate) {
48         this.ignoredForThingUpdate = ignoredForThingUpdate;
49     }
50 }