19#ifndef MBED_GATT_SERVICE_H__
20#define MBED_GATT_SERVICE_H__
23#include "ble/gatt/GattCharacteristic.h"
154 unsigned numCharacteristics
156 _primaryServiceID(uuid),
157 _characteristicCount(numCharacteristics),
158 _characteristics(characteristics),
169 return _primaryServiceID;
189 return _characteristicCount;
213 if (index >= _characteristicCount) {
217 return _characteristics[index];
224 UUID _primaryServiceID;
229 uint8_t _characteristicCount;
Representation of a GattServer characteristic.
Representation of a GattServer service.
void setHandle(uint16_t handle)
Set the handle of the service declaration attribute in the ATT table.
uint16_t getHandle() const
Get the handle of the service declaration attribute in the ATT table.
@ UUID_CURRENT_TIME_SERVICE
UUID of the Current Time service.
@ UUID_LINK_LOSS_SERVICE
UUID of the Link Loss service.
@ UUID_BLOOD_PRESSURE_SERVICE
UUID of the Blood Pressure service.
@ UUID_HEART_RATE_SERVICE
UUID of the Heart Rate service.
@ UUID_NEXT_DST_CHANGE_SERVICE
UUID of the Next DST change service.
@ UUID_HUMAN_INTERFACE_DEVICE_SERVICE
UUID of the Human Interface Device (HID) service.
@ UUID_BATTERY_SERVICE
UUID of the Battery service.
@ UUID_PHONE_ALERT_STATUS_SERVICE
UUID of the Phone Alert Status service.
@ UUID_ENVIRONMENTAL_SERVICE
UUID of the environmental service.
@ UUID_IMMEDIATE_ALERT_SERVICE
UUID of the Immediate Alert service.
@ UUID_CYCLING_SPEED_AND_CADENCE
UUID of the Cycling Speed and Cadence (CSC) service.
@ UUID_GLUCOSE_SERVICE
UUID of the Glucose service.
@ UUID_DEVICE_INFORMATION_SERVICE
UUID of the Device Information Service (DIS).
@ UUID_ALERT_NOTIFICATION_SERVICE
UUID of the Alert Notification service.
@ UUID_HEALTH_THERMOMETER_SERVICE
UUID of the health thermometer.
@ UUID_REFERENCE_TIME_UPDATE_SERVICE
UUID of the Reference Time Update service.
@ UUID_RUNNING_SPEED_AND_CADENCE
UUID of the Running Speed and Cadence (RSC) service.
@ UUID_TX_POWER_SERVICE
UUID of the TX power service.
@ UUID_SCAN_PARAMETERS_SERVICE
UUID of the Scan Parameter service.
GattCharacteristic * getCharacteristic(uint8_t index)
Get this service's characteristic at a specific index.
GattService(const UUID &uuid, GattCharacteristic *characteristics[], unsigned numCharacteristics)
Construct a GattService.
uint8_t getCharacteristicCount() const
Get the total number of characteristics within this service.
const UUID & getUUID() const
Get this service's UUID.
Representation of a Universally Unique Identifier (UUID).