]> git.basschouten.com Git - openhab-addons.git/blob
753e26716c625941f6187bce490954d92f7bb23b
[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.smartthings.internal;
14
15 import java.util.concurrent.ExecutionException;
16 import java.util.concurrent.TimeoutException;
17
18 import org.eclipse.jdt.annotation.NonNull;
19 import org.openhab.core.thing.ThingUID;
20
21 /**
22  * This interface is responsible sending commands to the Smartthings Hub
23  * handlers.
24  *
25  * @author Bob Raker - Initial contribution
26  */
27 public interface SmartthingsHubCommand {
28
29     /**
30      * Send a command to the Smartthings Hub
31      *
32      * @param path http path which tells Smartthings what to execute
33      * @param data data to send
34      * @throws InterruptedException
35      * @throws TimeoutException
36      * @throws ExecutionException
37      */
38     void sendDeviceCommand(@NonNull String path, int timeout, @NonNull String data)
39             throws InterruptedException, TimeoutException, ExecutionException;
40
41     ThingUID getBridgeUID();
42 }