| OLD | NEW | 
|---|
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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/BluetoothError.h" | 5 #include "modules/bluetooth/BluetoothError.h" | 
| 6 | 6 | 
| 7 #include "core/dom/DOMException.h" | 7 #include "core/dom/DOMException.h" | 
| 8 #include "core/dom/ExceptionCode.h" | 8 #include "core/dom/ExceptionCode.h" | 
| 9 | 9 | 
| 10 namespace blink { | 10 namespace blink { | 
| (...skipping 10 matching lines...) Expand all  Loading... | 
| 21 | 21 | 
| 22       // InvalidModificationErrors: | 22       // InvalidModificationErrors: | 
| 23       MAP_ERROR(GATT_INVALID_ATTRIBUTE_LENGTH, InvalidModificationError, | 23       MAP_ERROR(GATT_INVALID_ATTRIBUTE_LENGTH, InvalidModificationError, | 
| 24                 "GATT Error: invalid attribute length."); | 24                 "GATT Error: invalid attribute length."); | 
| 25 | 25 | 
| 26       // InvalidStateErrors: | 26       // InvalidStateErrors: | 
| 27       MAP_ERROR(SERVICE_NO_LONGER_EXISTS, InvalidStateError, | 27       MAP_ERROR(SERVICE_NO_LONGER_EXISTS, InvalidStateError, | 
| 28                 "GATT Service no longer exists."); | 28                 "GATT Service no longer exists."); | 
| 29       MAP_ERROR(CHARACTERISTIC_NO_LONGER_EXISTS, InvalidStateError, | 29       MAP_ERROR(CHARACTERISTIC_NO_LONGER_EXISTS, InvalidStateError, | 
| 30                 "GATT Characteristic no longer exists."); | 30                 "GATT Characteristic no longer exists."); | 
|  | 31       MAP_ERROR(DESCRIPTOR_NO_LONGER_EXISTS, InvalidStateError, | 
|  | 32                 "GATT Descriptor no longer exists."); | 
| 31 | 33 | 
| 32       // NetworkErrors: | 34       // NetworkErrors: | 
| 33       MAP_ERROR(CONNECT_ALREADY_IN_PROGRESS, NetworkError, | 35       MAP_ERROR(CONNECT_ALREADY_IN_PROGRESS, NetworkError, | 
| 34                 "Connection already in progress."); | 36                 "Connection already in progress."); | 
| 35       MAP_ERROR(CONNECT_ATTRIBUTE_LENGTH_INVALID, NetworkError, | 37       MAP_ERROR(CONNECT_ATTRIBUTE_LENGTH_INVALID, NetworkError, | 
| 36                 "Write operation exceeds the maximum length of the attribute."); | 38                 "Write operation exceeds the maximum length of the attribute."); | 
| 37       MAP_ERROR(CONNECT_AUTH_CANCELED, NetworkError, | 39       MAP_ERROR(CONNECT_AUTH_CANCELED, NetworkError, | 
| 38                 "Authentication canceled."); | 40                 "Authentication canceled."); | 
| 39       MAP_ERROR(CONNECT_AUTH_FAILED, NetworkError, "Authentication failed."); | 41       MAP_ERROR(CONNECT_AUTH_FAILED, NetworkError, "Authentication failed."); | 
| 40       MAP_ERROR(CONNECT_AUTH_REJECTED, NetworkError, | 42       MAP_ERROR(CONNECT_AUTH_REJECTED, NetworkError, | 
| (...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 142                 "No window to show the requestDevice() dialog."); | 144                 "No window to show the requestDevice() dialog."); | 
| 143 | 145 | 
| 144 #undef MAP_ERROR | 146 #undef MAP_ERROR | 
| 145   } | 147   } | 
| 146 | 148 | 
| 147   ASSERT_NOT_REACHED(); | 149   ASSERT_NOT_REACHED(); | 
| 148   return DOMException::create(UnknownError); | 150   return DOMException::create(UnknownError); | 
| 149 } | 151 } | 
| 150 | 152 | 
| 151 }  // namespace blink | 153 }  // namespace blink | 
| OLD | NEW | 
|---|