-
Notifications
You must be signed in to change notification settings - Fork 232
/
Copy pathHAPIPCharacteristic.h
61 lines (51 loc) · 1.57 KB
/
HAPIPCharacteristic.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
// Copyright (c) 2015-2019 The HomeKit ADK Contributors
//
// Licensed under the Apache License, Version 2.0 (the “License”);
// you may not use this file except in compliance with the License.
// See [CONTRIBUTORS.md] for the list of HomeKit ADK project authors.
#ifndef HAP_IP_CHARACTERISTIC_H
#define HAP_IP_CHARACTERISTIC_H
#ifdef __cplusplus
extern "C" {
#endif
#include "HAP+Internal.h"
#if __has_feature(nullability)
#pragma clang assume_nonnull begin
#endif
/**
* Returns whether a characteristic supports HAP over IP (Ethernet / Wi-Fi).
*
* - Certain characteristics are only applicable to HAP over Bluetooth LE.
*
* @param characteristic Characteristic.
*
* @return true If the characteristic supports HAP over IP (Ethernet / Wi-Fi).
* @return false Otherwise.
*/
HAP_RESULT_USE_CHECK
bool HAPIPCharacteristicIsSupported(const HAPCharacteristic* characteristic);
/**
* Returns the number of enabled properties of a characteristic.
*
* @param characteristic Characteristic.
*
* @return Number of enabled properties.
*/
HAP_RESULT_USE_CHECK
size_t HAPCharacteristicGetNumEnabledProperties(const HAPCharacteristic* characteristic);
/**
* Returns the unit of the characteristic value.
*
* @param characteristic Characteristic.
*
* @return Unit of the characteristic value.
*/
HAP_RESULT_USE_CHECK
HAPCharacteristicUnits HAPCharacteristicGetUnit(const HAPCharacteristic* characteristic);
#if __has_feature(nullability)
#pragma clang assume_nonnull end
#endif
#ifdef __cplusplus
}
#endif
#endif