]> git.basschouten.com Git - openhab-addons.git/blob
d31f0c77aeb8f9d1d2f30d055037779302d4173b
[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.network.internal;
14
15 import java.util.Set;
16
17 import org.eclipse.jdt.annotation.NonNullByDefault;
18 import org.openhab.core.thing.ThingTypeUID;
19
20 /**
21  * The {@link NetworkBindingConstants} class defines common constants, which are
22  * used across the whole binding.
23  *
24  * @author Marc Mettke - Initial contribution
25  * @author David Gräff - 2016, Add dhcp listen
26  */
27 @NonNullByDefault
28 public class NetworkBindingConstants {
29
30     private static final String BINDING_ID = "network";
31
32     // List of all Thing Type UIDs
33     public static final ThingTypeUID BACKWARDS_COMPATIBLE_DEVICE = new ThingTypeUID(BINDING_ID, "device");
34     public static final ThingTypeUID PING_DEVICE = new ThingTypeUID(BINDING_ID, "pingdevice");
35     public static final ThingTypeUID SERVICE_DEVICE = new ThingTypeUID(BINDING_ID, "servicedevice");
36     public static final ThingTypeUID SPEEDTEST_DEVICE = new ThingTypeUID(BINDING_ID, "speedtest");
37
38     public static final Set<ThingTypeUID> SUPPORTED_THING_TYPES_UIDS = Set.of(BACKWARDS_COMPATIBLE_DEVICE, PING_DEVICE,
39             SERVICE_DEVICE, SPEEDTEST_DEVICE);
40
41     // List of all Channel ids
42     public static final String CHANNEL_ONLINE = "online";
43     public static final String CHANNEL_LATENCY = "latency";
44     public static final String CHANNEL_LASTSEEN = "lastseen";
45     public static final String CHANNEL_TEST_ISRUNNING = "isRunning";
46     public static final String CHANNEL_TEST_PROGRESS = "progress";
47     public static final String CHANNEL_RATE_UP = "rateUp";
48     public static final String CHANNEL_RATE_DOWN = "rateDown";
49     public static final String CHANNEL_TEST_START = "testStart";
50     public static final String CHANNEL_TEST_END = "testEnd";
51
52     // List of all Parameters
53     public static final String PARAMETER_HOSTNAME = "hostname";
54     public static final String PARAMETER_RETRY = "retry";
55     public static final String PARAMETER_TIMEOUT = "timeout";
56     public static final String PARAMETER_REFRESH_INTERVAL = "refreshInterval";
57     public static final String PARAMETER_PORT = "port";
58
59     public static final String PROPERTY_DHCP_STATE = "dhcp_state";
60     public static final String PROPERTY_ARP_STATE = "arp_state";
61     public static final String PROPERTY_ICMP_STATE = "icmp_state";
62     public static final String PROPERTY_PRESENCE_DETECTION_TYPE = "presence_detection_type";
63     public static final String PROPERTY_IOS_WAKEUP = "uses_ios_wakeup";
64 }