Home | History | Annotate | Download | only in bluetooth

Lines Matching defs:characteristic

48 // Compares GATT characteristic/descriptor values. Returns true, if the values
172 BluetoothGattCharacteristic* characteristic) OVERRIDE {
176 last_gatt_characteristic_id_ = characteristic->GetIdentifier();
177 last_gatt_characteristic_uuid_ = characteristic->GetUUID();
180 characteristic);
181 EXPECT_EQ(service, characteristic->GetService());
188 BluetoothGattCharacteristic* characteristic) OVERRIDE {
192 last_gatt_characteristic_id_ = characteristic->GetIdentifier();
193 last_gatt_characteristic_uuid_ = characteristic->GetUUID();
195 // The service should return NULL for this characteristic.
197 EXPECT_EQ(service, characteristic->GetService());
204 BluetoothGattCharacteristic* characteristic,
209 last_gatt_characteristic_id_ = characteristic->GetIdentifier();
210 last_gatt_characteristic_uuid_ = characteristic->GetUUID();
214 characteristic);
215 EXPECT_EQ(service, characteristic->GetService());
221 BluetoothGattCharacteristic* characteristic,
223 ASSERT_EQ(gatt_service_id_, characteristic->GetService()->GetIdentifier());
229 EXPECT_EQ(characteristic->GetDescriptor(last_gatt_descriptor_id_),
231 EXPECT_EQ(characteristic, descriptor->GetCharacteristic());
237 BluetoothGattCharacteristic* characteristic,
239 ASSERT_EQ(gatt_service_id_, characteristic->GetService()->GetIdentifier());
245 // The characteristic should return NULL for this descriptor..
246 EXPECT_FALSE(characteristic->GetDescriptor(last_gatt_descriptor_id_));
247 EXPECT_EQ(characteristic, descriptor->GetCharacteristic());
253 BluetoothGattCharacteristic* characteristic,
256 ASSERT_EQ(gatt_service_id_, characteristic->GetService()->GetIdentifier());
263 EXPECT_EQ(characteristic->GetDescriptor(last_gatt_descriptor_id_),
265 EXPECT_EQ(characteristic, descriptor->GetCharacteristic());
684 // Only the Heart Rate Measurement characteristic has a descriptor.
689 BluetoothGattCharacteristic* characteristic = service->GetCharacteristic(
692 ASSERT_TRUE(characteristic);
693 EXPECT_TRUE(characteristic->GetDescriptors().empty());
695 characteristic = service->GetCharacteristic(
698 ASSERT_TRUE(characteristic);
699 EXPECT_TRUE(characteristic->GetDescriptors().empty());
701 characteristic = service->GetCharacteristic(
704 ASSERT_TRUE(characteristic);
705 EXPECT_EQ(1U, characteristic->GetDescriptors().size());
707 BluetoothGattDescriptor* descriptor = characteristic->GetDescriptors()[0];
719 EXPECT_TRUE(characteristic->GetDescriptors().empty());
729 dbus::ObjectPath(characteristic->GetIdentifier()),
733 EXPECT_EQ(1U, characteristic->GetDescriptors().size());
738 descriptor = characteristic->GetDescriptors()[0];
783 BluetoothGattCharacteristic* characteristic = service->GetCharacteristic(
786 ASSERT_TRUE(characteristic);
790 characteristic->GetUUID());
791 EXPECT_FALSE(characteristic->IsLocal());
792 EXPECT_TRUE(characteristic->GetDescriptors().empty());
794 characteristic = service->GetCharacteristic(
797 ASSERT_TRUE(characteristic);
801 characteristic->GetUUID());
802 EXPECT_FALSE(characteristic->IsLocal());
803 EXPECT_TRUE(characteristic->GetDescriptors().empty());
805 characteristic = service->GetCharacteristic(
808 ASSERT_TRUE(characteristic);
812 characteristic->GetUUID());
813 EXPECT_FALSE(characteristic->IsLocal());
814 EXPECT_EQ(1U, characteristic->GetDescriptors().size());
816 BluetoothGattDescriptor* descriptor = characteristic->GetDescriptors()[0];
854 BluetoothGattCharacteristic* characteristic =
857 ASSERT_TRUE(characteristic);
858 EXPECT_FALSE(characteristic->IsNotifying());
861 characteristic->GetIdentifier());
862 EXPECT_EQ(kHeartRateMeasurementUUID, characteristic->GetUUID());
863 characteristic->WriteRemoteCharacteristic(
875 characteristic = service->GetCharacteristic(
878 ASSERT_TRUE(characteristic);
881 characteristic->GetIdentifier());
882 EXPECT_EQ(kBodySensorLocationUUID, characteristic->GetUUID());
883 characteristic->WriteRemoteCharacteristic(
895 // Issue write request to writeable characteristic. The "Body Sensor Location"
896 // characteristic does not send notifications and WriteValue does not result
899 characteristic = service->GetCharacteristic(
902 ASSERT_TRUE(characteristic);
905 characteristic->GetIdentifier());
906 EXPECT_EQ(kHeartRateControlPointUUID, characteristic->GetUUID());
907 characteristic->WriteRemoteCharacteristic(
921 characteristic = service->GetCharacteristic(
924 ASSERT_TRUE(characteristic);
927 characteristic->GetIdentifier());
928 EXPECT_EQ(kBodySensorLocationUUID, characteristic->GetUUID());
929 characteristic->ReadRemoteCharacteristic(
937 EXPECT_TRUE(ValuesEqual(characteristic->GetValue(), last_read_value_));
964 BluetoothGattCharacteristic *characteristic = service->GetCharacteristic(
968 characteristic->GetProperties());
970 characteristic = service->GetCharacteristic(
974 characteristic->GetProperties());
976 characteristic = service->GetCharacteristic(
980 characteristic->GetProperties());
1011 // Only the Heart Rate Measurement characteristic has a descriptor.
1012 BluetoothGattCharacteristic* characteristic = service->GetCharacteristic(
1015 ASSERT_TRUE(characteristic);
1016 EXPECT_EQ(1U, characteristic->GetDescriptors().size());
1018 BluetoothGattDescriptor* descriptor = characteristic->GetDescriptors()[0];
1103 BluetoothGattCharacteristic* characteristic = service->GetCharacteristic(
1106 ASSERT_TRUE(characteristic);
1107 EXPECT_FALSE(characteristic->IsNotifying());
1111 characteristic->StartNotifySession(
1125 characteristic->StartNotifySession(
1130 characteristic->StartNotifySession(
1139 EXPECT_TRUE(characteristic->IsNotifying());
1155 // characteristic should still be notifying.
1163 EXPECT_EQ(characteristic->GetIdentifier(),
1165 EXPECT_TRUE(characteristic->IsNotifying());
1167 // Delete another session. Characteristic should still be notifying.
1170 EXPECT_TRUE(characteristic->IsNotifying());
1177 EXPECT_FALSE(characteristic->IsNotifying());
1183 characteristic->StartNotifySession(
1192 EXPECT_TRUE(characteristic->IsNotifying());
1202 EXPECT_TRUE(characteristic->IsNotifying());
1209 characteristic->StartNotifySession(
1219 EXPECT_TRUE(characteristic->IsNotifying());
1221 // Hide the characteristic. The sessions should become inactive.
1253 BluetoothGattCharacteristic* characteristic = service->GetCharacteristic(
1256 ASSERT_TRUE(characteristic);
1257 EXPECT_FALSE(characteristic->IsNotifying());
1261 characteristic->StartNotifySession(
1266 characteristic->StartNotifySession(
1271 characteristic->StartNotifySession(
1276 characteristic->StartNotifySession(
1287 EXPECT_TRUE(characteristic->IsNotifying());
1297 EXPECT_TRUE(characteristic->IsNotifying());
1313 EXPECT_FALSE(characteristic->IsNotifying());
1324 characteristic->StartNotifySession(
1333 EXPECT_TRUE(characteristic->IsNotifying());
1341 EXPECT_TRUE(characteristic->IsNotifying());