Skip to content

Commit

Permalink
Suppress warnings of deprecated API in deprecated services
Browse files Browse the repository at this point in the history
Services that already have deprecation notices in place should
not trigger more warnings from the compiler.
  • Loading branch information
LDong-Arm committed May 22, 2019
1 parent 31edc25 commit d10ec03
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 0 deletions.
5 changes: 5 additions & 0 deletions features/FEATURE_BLE/ble/services/UARTService.h
Expand Up @@ -26,9 +26,12 @@

#include "ble/UUID.h"
#include "ble/BLE.h"
#include "Deprecated.h"

#if BLE_FEATURE_GATT_SERVER

BLE_DEPRECATED_API_USE_BEGIN()

extern const uint8_t UARTServiceBaseUUID[UUID::LENGTH_OF_LONG_UUID];
extern const uint16_t UARTServiceShortUUID;
extern const uint16_t UARTServiceTXCharacteristicShortUUID;
Expand Down Expand Up @@ -223,6 +226,8 @@ class UARTService {
* application. */
};

BLE_DEPRECATED_API_USE_END()

#endif // BLE_FEATURE_GATT_SERVER

#endif /* #ifndef __BLE_UART_SERVICE_H__*/
5 changes: 5 additions & 0 deletions features/FEATURE_BLE/ble/services/URIBeaconConfigService.h
Expand Up @@ -18,6 +18,7 @@
#define SERVICES_URIBEACONCONFIGSERVICE_H_

#include "ble/BLE.h"
#include "Deprecated.h"

#ifdef YOTTA_CFG_MBED_OS
#include "mbed-drivers/mbed.h"
Expand All @@ -28,6 +29,8 @@
#if BLE_FEATURE_GATT_SERVER
#if BLE_ROLE_BROADCASTER

BLE_DEPRECATED_API_USE_BEGIN()

extern const uint8_t UUID_URI_BEACON_SERVICE[UUID::LENGTH_OF_LONG_UUID];
extern const uint8_t UUID_LOCK_STATE_CHAR[UUID::LENGTH_OF_LONG_UUID];
extern const uint8_t UUID_LOCK_CHAR[UUID::LENGTH_OF_LONG_UUID];
Expand Down Expand Up @@ -483,6 +486,8 @@ class URIBeaconConfigService {
}
};

BLE_DEPRECATED_API_USE_END()

#endif // BLE_ROLE_BROADCASTER
#endif // BLE_FEATURE_GATT_SERVER

Expand Down
4 changes: 4 additions & 0 deletions features/FEATURE_BLE/ble/services/iBeacon.h
Expand Up @@ -21,6 +21,8 @@

#if BLE_FEATURE_GATT_SERVER

BLE_DEPRECATED_API_USE_BEGIN()

/**
* iBeacon Service.
*
Expand Down Expand Up @@ -253,6 +255,8 @@ class iBeacon {
*/
typedef iBeacon iBeaconService;

BLE_DEPRECATED_API_USE_END()

#endif // BLE_FEATURE_GATT_SERVER

#endif //MBED_BLE_IBEACON_H__

0 comments on commit d10ec03

Please sign in to comment.