Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(96)

Side by Side Diff: third_party/WebKit/Source/modules/bluetooth/BluetoothRemoteGATTUtils.cpp

Issue 2637343002: Implement WebBluetooth descriptor.readValue() (Closed)
Patch Set: run bad_message_reasons Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2017 The Chromium Authors. All rights reserved. 1 // Copyright 2017 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "modules/bluetooth/BluetoothRemoteGATTUtils.h" 5 #include "modules/bluetooth/BluetoothRemoteGATTUtils.h"
6 6
7 namespace blink { 7 namespace blink {
8 8
9 // static 9 // static
10 DOMDataView* BluetoothRemoteGATTUtils::ConvertWTFVectorToDataView( 10 DOMDataView* BluetoothRemoteGATTUtils::ConvertWTFVectorToDataView(
(...skipping 17 matching lines...) Expand all
28 return DOMException::create( 28 return DOMException::create(
29 NetworkError, 29 NetworkError,
30 "GATT Server is disconnected. Cannot perform GATT operations."); 30 "GATT Server is disconnected. Cannot perform GATT operations.");
31 31
32 case ExceptionType::kInvalidCharacteristic: 32 case ExceptionType::kInvalidCharacteristic:
33 return DOMException::create( 33 return DOMException::create(
34 InvalidStateError, 34 InvalidStateError,
35 "Characteristic is no longer valid. Remember to retrieve the " 35 "Characteristic is no longer valid. Remember to retrieve the "
36 "characteristic again after reconnecting."); 36 "characteristic again after reconnecting.");
37 37
38 case ExceptionType::kInvalidDescriptor:
39 return DOMException::create(
40 InvalidStateError,
41 "Descriptor is no longer valid. Remember to retrieve the "
42 "Descriptor again after reconnecting.");
43
38 default: 44 default:
39 NOTREACHED(); 45 NOTREACHED();
40 return nullptr; 46 return nullptr;
41 } 47 }
42 } 48 }
43 49
44 } // namespace blink 50 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698