| 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:collection'; | 7 import 'dart:collection'; |
| 8 import 'dart:convert'; | 8 import 'dart:convert'; |
| 9 | 9 |
| 10 part 'generated_protocol.dart'; | 10 part 'generated_protocol.dart'; |
| (...skipping 779 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 790 /** | 790 /** |
| 791 * Initialize a newly created instance to represent an error condition caused | 791 * Initialize a newly created instance to represent an error condition caused |
| 792 * by a malformed request. | 792 * by a malformed request. |
| 793 */ | 793 */ |
| 794 Response.invalidRequestFormat() | 794 Response.invalidRequestFormat() |
| 795 : this( | 795 : this( |
| 796 '', | 796 '', |
| 797 error: new RequestError(RequestErrorCode.INVALID_REQUEST, 'Invalid req
uest')); | 797 error: new RequestError(RequestErrorCode.INVALID_REQUEST, 'Invalid req
uest')); |
| 798 | 798 |
| 799 /** | 799 /** |
| 800 * Initialize a newly created instance to represent an error condition caused |
| 801 * by a request that requires an index, but indexing is disabled. |
| 802 */ |
| 803 Response.noIndexGenerated(Request request) |
| 804 : this( |
| 805 request.id, |
| 806 error: new RequestError( |
| 807 RequestErrorCode.NO_INDEX_GENERATED, |
| 808 'Indexing is disabled')); |
| 809 |
| 810 /** |
| 800 * Initialize a newly created instance to represent the | 811 * Initialize a newly created instance to represent the |
| 801 * REFACTORING_REQUEST_CANCELLED error condition. | 812 * REFACTORING_REQUEST_CANCELLED error condition. |
| 802 */ | 813 */ |
| 803 Response.refactoringRequestCancelled(Request request) | 814 Response.refactoringRequestCancelled(Request request) |
| 804 : this( | 815 : this( |
| 805 request.id, | 816 request.id, |
| 806 error: new RequestError( | 817 error: new RequestError( |
| 807 RequestErrorCode.REFACTORING_REQUEST_CANCELLED, | 818 RequestErrorCode.REFACTORING_REQUEST_CANCELLED, |
| 808 'The `edit.getRefactoring` request was cancelled.')); | 819 'The `edit.getRefactoring` request was cancelled.')); |
| 809 | 820 |
| (...skipping 112 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 922 hash = 0x1fffffff & (hash + ((0x03ffffff & hash) << 3)); | 933 hash = 0x1fffffff & (hash + ((0x03ffffff & hash) << 3)); |
| 923 hash = hash ^ (hash >> 11); | 934 hash = hash ^ (hash >> 11); |
| 924 return 0x1fffffff & (hash + ((0x00003fff & hash) << 15)); | 935 return 0x1fffffff & (hash + ((0x00003fff & hash) << 15)); |
| 925 } | 936 } |
| 926 | 937 |
| 927 static int hash2(a, b) => finish(combine(combine(0, a), b)); | 938 static int hash2(a, b) => finish(combine(combine(0, a), b)); |
| 928 | 939 |
| 929 static int hash4(a, b, c, d) => | 940 static int hash4(a, b, c, d) => |
| 930 finish(combine(combine(combine(combine(0, a), b), c), d)); | 941 finish(combine(combine(combine(combine(0, a), b), c), d)); |
| 931 } | 942 } |
| OLD | NEW |