]> git.basschouten.com Git - openhab-addons.git/blob
d7c9edfe3d7d56187a41f6b36771dc89cb9f89df
[openhab-addons.git] /
1 /**
2  * Copyright (c) 2010-2024 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.openweathermap.internal;
14
15 import org.eclipse.jdt.annotation.NonNullByDefault;
16 import org.openhab.core.thing.ThingTypeUID;
17 import org.openhab.core.thing.type.ChannelGroupTypeUID;
18
19 /**
20  * The {@link OpenWeatherMapBindingConstants} class defines common constants, which are used across the whole binding.
21  *
22  * @author Christoph Weitkamp - Initial contribution
23  */
24 @NonNullByDefault
25 public class OpenWeatherMapBindingConstants {
26
27     public static final String BINDING_ID = "openweathermap";
28
29     public static final String API = "api";
30     public static final String LOCAL = "local";
31
32     // Bridge
33     public static final ThingTypeUID THING_TYPE_WEATHER_API = new ThingTypeUID(BINDING_ID, "weather-api");
34
35     // Thing
36     public static final ThingTypeUID THING_TYPE_WEATHER_AND_FORECAST = new ThingTypeUID(BINDING_ID,
37             "weather-and-forecast");
38     public static final ThingTypeUID THING_TYPE_AIR_POLLUTION = new ThingTypeUID(BINDING_ID, "air-pollution");
39     // One Call API forecast
40     public static final ThingTypeUID THING_TYPE_ONECALL_WEATHER_AND_FORECAST = new ThingTypeUID(BINDING_ID, "onecall");
41     // One Call API historical data
42     public static final ThingTypeUID THING_TYPE_ONECALL_HISTORY = new ThingTypeUID(BINDING_ID, "onecall-history");
43
44     // List of all properties
45     public static final String CONFIG_API_KEY = "apikey";
46     public static final String CONFIG_LANGUAGE = "language";
47     public static final String CONFIG_LOCATION = "location";
48
49     // Channel group types
50     public static final ChannelGroupTypeUID CHANNEL_GROUP_TYPE_STATION = new ChannelGroupTypeUID(BINDING_ID, "station");
51     public static final ChannelGroupTypeUID CHANNEL_GROUP_TYPE_HOURLY_FORECAST = new ChannelGroupTypeUID(BINDING_ID,
52             "hourlyForecast");
53     public static final ChannelGroupTypeUID CHANNEL_GROUP_TYPE_DAILY_FORECAST = new ChannelGroupTypeUID(BINDING_ID,
54             "dailyForecast");
55     public static final ChannelGroupTypeUID CHANNEL_GROUP_TYPE_AIR_POLLUTION_FORECAST = new ChannelGroupTypeUID(
56             BINDING_ID, "airPollutionForecast");
57     public static final ChannelGroupTypeUID CHANNEL_GROUP_TYPE_ONECALL_MINUTELY_FORECAST = new ChannelGroupTypeUID(
58             BINDING_ID, "oneCallMinutely");
59     public static final ChannelGroupTypeUID CHANNEL_GROUP_TYPE_ONECALL_HOURLY_FORECAST = new ChannelGroupTypeUID(
60             BINDING_ID, "oneCallHourly");
61     public static final ChannelGroupTypeUID CHANNEL_GROUP_TYPE_ONECALL_DAILY_FORECAST = new ChannelGroupTypeUID(
62             BINDING_ID, "oneCallDaily");
63     public static final ChannelGroupTypeUID CHANNEL_GROUP_TYPE_ONECALL_CURRENT = new ChannelGroupTypeUID(BINDING_ID,
64             "oneCallCurrent");
65     public static final ChannelGroupTypeUID CHANNEL_GROUP_TYPE_ONECALL_ALERTS = new ChannelGroupTypeUID(BINDING_ID,
66             "oneCallAlerts");
67
68     // List of all channel groups
69     public static final String CHANNEL_GROUP_STATION = "station";
70     public static final String CHANNEL_GROUP_CURRENT_WEATHER = "current";
71     public static final String CHANNEL_GROUP_FORECAST_TODAY = "forecastToday";
72     public static final String CHANNEL_GROUP_FORECAST_TOMORROW = "forecastTomorrow";
73     public static final String CHANNEL_GROUP_CURRENT_AIR_POLLUTION = "current";
74     public static final String CHANNEL_GROUP_ONECALL_CURRENT = "current";
75     public static final String CHANNEL_GROUP_ONECALL_HISTORY = "history";
76     public static final String CHANNEL_GROUP_ONECALL_TODAY = "forecastToday";
77     public static final String CHANNEL_GROUP_ONECALL_TOMORROW = "forecastTomorrow";
78
79     // List of all channels
80     public static final String CHANNEL_STATION_ID = "id";
81     public static final String CHANNEL_STATION_NAME = "name";
82     public static final String CHANNEL_STATION_LOCATION = "location";
83     public static final String CHANNEL_TIME_STAMP = "time-stamp";
84     public static final String CHANNEL_SUNRISE = "sunrise";
85     public static final String CHANNEL_SUNSET = "sunset";
86     public static final String CHANNEL_MOONRISE = "moonrise";
87     public static final String CHANNEL_MOONSET = "moonset";
88     public static final String CHANNEL_MOON_PHASE = "moon-phase";
89     public static final String CHANNEL_CONDITION = "condition";
90     public static final String CHANNEL_CONDITION_ID = "condition-id";
91     public static final String CHANNEL_CONDITION_ICON = "icon";
92     public static final String CHANNEL_CONDITION_ICON_ID = "icon-id";
93     public static final String CHANNEL_TEMPERATURE = "temperature";
94     public static final String CHANNEL_APPARENT_TEMPERATURE = "apparent-temperature";
95     public static final String CHANNEL_APPARENT_MORNING = "apparent-morning";
96     public static final String CHANNEL_APPARENT_DAY = "apparent-day";
97     public static final String CHANNEL_APPARENT_EVENING = "apparent-evening";
98     public static final String CHANNEL_APPARENT_NIGHT = "apparent-night";
99     public static final String CHANNEL_MIN_TEMPERATURE = "min-temperature";
100     public static final String CHANNEL_MAX_TEMPERATURE = "max-temperature";
101     public static final String CHANNEL_MORNING_TEMPERATURE = "morning-temperature";
102     public static final String CHANNEL_DAY_TEMPERATURE = "day-temperature";
103     public static final String CHANNEL_EVENING_TEMPERATURE = "evening-temperature";
104     public static final String CHANNEL_NIGHT_TEMPERATURE = "night-temperature";
105     public static final String CHANNEL_DEW_POINT = "dew-point";
106     public static final String CHANNEL_PRESSURE = "pressure";
107     public static final String CHANNEL_HUMIDITY = "humidity";
108     public static final String CHANNEL_WIND_SPEED = "wind-speed";
109     public static final String CHANNEL_WIND_DIRECTION = "wind-direction";
110     public static final String CHANNEL_GUST_SPEED = "gust-speed";
111     public static final String CHANNEL_CLOUDINESS = "cloudiness";
112     public static final String CHANNEL_PRECIP_PROBABILITY = "precip-probability";
113     public static final String CHANNEL_RAIN = "rain";
114     public static final String CHANNEL_SNOW = "snow";
115     public static final String CHANNEL_VISIBILITY = "visibility";
116     public static final String CHANNEL_UVINDEX = "uvindex";
117     public static final String CHANNEL_AIR_QUALITY_INDEX = "airQualityIndex";
118     public static final String CHANNEL_PARTICULATE_MATTER_2_5 = "particulateMatter2dot5";
119     public static final String CHANNEL_PARTICULATE_MATTER_10 = "particulateMatter10";
120     public static final String CHANNEL_CARBON_MONOXIDE = "carbonMonoxide";
121     public static final String CHANNEL_NITROGEN_MONOXIDE = "nitrogenMonoxide";
122     public static final String CHANNEL_NITROGEN_DIOXIDE = "nitrogenDioxide";
123     public static final String CHANNEL_OZONE = "ozone";
124     public static final String CHANNEL_SULPHUR_DIOXIDE = "sulphurDioxide";
125     public static final String CHANNEL_AMMONIA = "ammonia";
126     public static final String CHANNEL_PRECIPITATION = "precipitation";
127     public static final String CHANNEL_ALERT_EVENT = "event";
128     public static final String CHANNEL_ALERT_DESCRIPTION = "description";
129     public static final String CHANNEL_ALERT_ONSET = "onset";
130     public static final String CHANNEL_ALERT_EXPIRES = "expires";
131     public static final String CHANNEL_ALERT_SOURCE = "source";
132
133     // List of all configuration
134     public static final String CONFIG_FORECAST_DAYS = "forecastDays";
135 }