Skip to content

Commit 1686cba

Browse files
committed
Allow Outlet to throw exception on set
Fix to match the signature on Outlet's setPowerState to other accessories setters.
1 parent 431a687 commit 1686cba

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

src/main/java/com/beowulfe/hap/accessories/Outlet.java

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,7 @@
44
import java.util.Collections;
55
import java.util.concurrent.CompletableFuture;
66

7-
import com.beowulfe.hap.HomekitAccessory;
8-
import com.beowulfe.hap.HomekitCharacteristicChangeCallback;
9-
import com.beowulfe.hap.Service;
7+
import com.beowulfe.hap.*;
108
import com.beowulfe.hap.impl.services.OutletService;
119

1210
/**
@@ -39,7 +37,7 @@ default public Collection<Service> getServices() {
3937
* @return a future that completes when the change is made
4038
* @throws Exception when the change cannot be made
4139
*/
42-
public CompletableFuture<Void> setPowerState(boolean state);
40+
public CompletableFuture<Void> setPowerState(boolean state) throws Exception;
4341

4442
/**
4543
* Subscribes to changes in the binary state of the outlet's power.

0 commit comments

Comments
 (0)