OLD | NEW |
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file |
2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
4 | 4 |
5 library protocol; | 5 library protocol; |
6 | 6 |
7 import 'dart:convert' show JsonDecoder; | 7 import 'dart:convert' show JsonDecoder; |
8 | 8 |
9 /** | 9 /** |
10 * Instances of the class [Request] represent a request that was received. | 10 * Instances of the class [Request] represent a request that was received. |
(...skipping 358 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
369 /** | 369 /** |
370 * An error code indicating one or more invalid parameters. | 370 * An error code indicating one or more invalid parameters. |
371 */ | 371 */ |
372 static const int CODE_INVALID_PARAMS = -32602; | 372 static const int CODE_INVALID_PARAMS = -32602; |
373 | 373 |
374 /** | 374 /** |
375 * An error code indicating an internal error. | 375 * An error code indicating an internal error. |
376 */ | 376 */ |
377 static const int CODE_INTERNAL_ERROR = -32603; | 377 static const int CODE_INTERNAL_ERROR = -32603; |
378 | 378 |
| 379 /** |
| 380 * An error code indicating a problem using the specified Dart SDK. |
| 381 */ |
| 382 static const int CODE_SDK_ERROR = -32603; |
| 383 |
379 /* | 384 /* |
380 * In addition, codes -32000 to -32099 indicate a server error. They are | 385 * In addition, codes -32000 to -32099 indicate a server error. They are |
381 * reserved for implementation-defined server-errors. | 386 * reserved for implementation-defined server-errors. |
382 */ | 387 */ |
383 | 388 |
384 /** | 389 /** |
385 * The code that uniquely identifies the error that occurred. | 390 * The code that uniquely identifies the error that occurred. |
386 */ | 391 */ |
387 final int code; | 392 final int code; |
388 | 393 |
(...skipping 190 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
579 /** | 584 /** |
580 * The response to be returned as a result of the failure. | 585 * The response to be returned as a result of the failure. |
581 */ | 586 */ |
582 final Response response; | 587 final Response response; |
583 | 588 |
584 /** | 589 /** |
585 * Initialize a newly created exception to return the given reponse. | 590 * Initialize a newly created exception to return the given reponse. |
586 */ | 591 */ |
587 RequestFailure(this.response); | 592 RequestFailure(this.response); |
588 } | 593 } |
OLD | NEW |