]> git.basschouten.com Git - openhab-addons.git/blob
6cc890c5b4b7d5128c77e160be9c854235abc677
[openhab-addons.git] /
1 /**
2  * Copyright (c) 2010-2021 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.opensprinkler.internal;
14
15 import org.eclipse.jdt.annotation.NonNullByDefault;
16 import org.openhab.core.thing.ThingTypeUID;
17
18 /**
19  * The {@link OpenSprinklerBinding} class defines common constants, which are
20  * used across the whole binding.
21  *
22  * @author Chris Graham - Initial contribution
23  * @author Florian Schmidt - Split channels to their own things
24  */
25 @NonNullByDefault
26 public class OpenSprinklerBindingConstants {
27     public static final String BINDING_ID = "opensprinkler";
28
29     // List of all Thing ids
30     public static final String HTTP_BRIDGE = "http";
31     public static final String PI_BRIDGE = "pi";
32     public static final String STATION_THING = "station";
33     public static final String DEVICE_THING = "device";
34
35     // List of all Thing Type UIDs
36     public static final ThingTypeUID OPENSPRINKLER_HTTP_BRIDGE = new ThingTypeUID(BINDING_ID, HTTP_BRIDGE);
37     public static final ThingTypeUID OPENSPRINKLER_STATION = new ThingTypeUID(BINDING_ID, STATION_THING);
38     public static final ThingTypeUID OPENSPRINKLER_DEVICE = new ThingTypeUID(BINDING_ID, DEVICE_THING);
39
40     public static final int DEFAULT_WAIT_BEFORE_INITIAL_REFRESH = 30;
41     public static final int DEFAULT_REFRESH_RATE = 60;
42     public static final int DISCOVERY_THREAD_POOL_SIZE = 15;
43     public static final boolean DISCOVERY_DEFAULT_AUTO_DISCOVER = false;
44     public static final int DISCOVERY_DEFAULT_TIMEOUT_RATE = 500;
45     public static final int DISCOVERY_DEFAULT_IP_TIMEOUT_RATE = 750;
46
47     // List of all Channel ids
48     public static final String SENSOR_RAIN = "rainsensor";
49     public static final String SENSOR_WATERLEVEL = "waterlevel";
50     public static final String SENSOR_CURRENT_DRAW = "currentDraw";
51     public static final String STATION_STATE = "stationState";
52     public static final String STATION_QUEUED = "queued";
53     public static final String REMAINING_WATER_TIME = "remainingWaterTime";
54     public static final String NEXT_DURATION = "nextDuration";
55 }