]> git.basschouten.com Git - openhab-addons.git/blob
8a3937638e90c5c7d0f9de3a82840fc3219178d7
[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.bluetooth.bluegiga;
14
15 import java.util.UUID;
16
17 import org.eclipse.jdt.annotation.NonNullByDefault;
18 import org.openhab.binding.bluetooth.BluetoothCharacteristic;
19
20 /**
21  * The {@link BlueGigaBluetoothCharacteristic} class extends BluetoothCharacteristic
22  * to provide write access to certain BluetoothCharacteristic fields that BlueGiga
23  * may not be initially aware of during characteristic construction but must be discovered
24  * later.
25  *
26  * @author Connor Petty - Initial contribution
27  *
28  */
29 @NonNullByDefault
30 public class BlueGigaBluetoothCharacteristic extends BluetoothCharacteristic {
31
32     private boolean notifying;
33
34     public BlueGigaBluetoothCharacteristic(int handle) {
35         super(null, handle);
36     }
37
38     @Override
39     public void setProperties(int properties) {
40         this.properties = properties;
41     }
42
43     public void setHandle(int handle) {
44         this.handle = handle;
45     }
46
47     public void setUUID(UUID uuid) {
48         this.uuid = uuid;
49     }
50
51     public boolean isNotifying() {
52         return notifying;
53     }
54
55     public void setNotifying(boolean enable) {
56         this.notifying = enable;
57     }
58 }