| 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 // This file has been automatically generated. Please do not edit it manually. | 5 // This file has been automatically generated. Please do not edit it manually. |
| 6 // To regenerate the file, use the script | 6 // To regenerate the file, use the script |
| 7 // "pkg/analysis_server/spec/generate_files". | 7 // "pkg/analysis_server/spec/generate_files". |
| 8 | 8 |
| 9 part of protocol2; | 9 part of protocol2; |
| 10 | 10 |
| (...skipping 8176 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 8187 /** | 8187 /** |
| 8188 * The file containing the code to be modified. | 8188 * The file containing the code to be modified. |
| 8189 */ | 8189 */ |
| 8190 String file; | 8190 String file; |
| 8191 | 8191 |
| 8192 /** | 8192 /** |
| 8193 * A list of the edits used to effect the change. | 8193 * A list of the edits used to effect the change. |
| 8194 */ | 8194 */ |
| 8195 List<SourceEdit> edits; | 8195 List<SourceEdit> edits; |
| 8196 | 8196 |
| 8197 SourceFileEdit(this.file, this.edits); | 8197 SourceFileEdit(this.file, {this.edits}) { |
| 8198 if (edits == null) { |
| 8199 edits = <SourceEdit>[]; |
| 8200 } |
| 8201 } |
| 8198 | 8202 |
| 8199 factory SourceFileEdit.fromJson(JsonDecoder jsonDecoder, String jsonPath, Obje
ct json) { | 8203 factory SourceFileEdit.fromJson(JsonDecoder jsonDecoder, String jsonPath, Obje
ct json) { |
| 8200 if (json == null) { | 8204 if (json == null) { |
| 8201 json = {}; | 8205 json = {}; |
| 8202 } | 8206 } |
| 8203 if (json is Map) { | 8207 if (json is Map) { |
| 8204 String file; | 8208 String file; |
| 8205 if (json.containsKey("file")) { | 8209 if (json.containsKey("file")) { |
| 8206 file = jsonDecoder._decodeString(jsonPath + ".file", json["file"]); | 8210 file = jsonDecoder._decodeString(jsonPath + ".file", json["file"]); |
| 8207 } else { | 8211 } else { |
| 8208 throw jsonDecoder.missingKey(jsonPath, "file"); | 8212 throw jsonDecoder.missingKey(jsonPath, "file"); |
| 8209 } | 8213 } |
| 8210 List<SourceEdit> edits; | 8214 List<SourceEdit> edits; |
| 8211 if (json.containsKey("edits")) { | 8215 if (json.containsKey("edits")) { |
| 8212 edits = jsonDecoder._decodeList(jsonPath + ".edits", json["edits"], (Str
ing jsonPath, Object json) => new SourceEdit.fromJson(jsonDecoder, jsonPath, jso
n)); | 8216 edits = jsonDecoder._decodeList(jsonPath + ".edits", json["edits"], (Str
ing jsonPath, Object json) => new SourceEdit.fromJson(jsonDecoder, jsonPath, jso
n)); |
| 8213 } else { | 8217 } else { |
| 8214 throw jsonDecoder.missingKey(jsonPath, "edits"); | 8218 throw jsonDecoder.missingKey(jsonPath, "edits"); |
| 8215 } | 8219 } |
| 8216 return new SourceFileEdit(file, edits); | 8220 return new SourceFileEdit(file, edits: edits); |
| 8217 } else { | 8221 } else { |
| 8218 throw jsonDecoder.mismatch(jsonPath, "SourceFileEdit"); | 8222 throw jsonDecoder.mismatch(jsonPath, "SourceFileEdit"); |
| 8219 } | 8223 } |
| 8220 } | 8224 } |
| 8221 | 8225 |
| 8222 Map<String, dynamic> toJson() { | 8226 Map<String, dynamic> toJson() { |
| 8223 Map<String, dynamic> result = {}; | 8227 Map<String, dynamic> result = {}; |
| 8224 result["file"] = file; | 8228 result["file"] = file; |
| 8225 result["edits"] = edits.map((SourceEdit value) => value.toJson()).toList(); | 8229 result["edits"] = edits.map((SourceEdit value) => value.toJson()).toList(); |
| 8226 return result; | 8230 return result; |
| (...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 8311 */ | 8315 */ |
| 8312 List<int> mixins; | 8316 List<int> mixins; |
| 8313 | 8317 |
| 8314 /** | 8318 /** |
| 8315 * The indexes of the items representing the subtypes of this class. The list | 8319 * The indexes of the items representing the subtypes of this class. The list |
| 8316 * will be empty if there are no subtypes or if this item represents a | 8320 * will be empty if there are no subtypes or if this item represents a |
| 8317 * supertype of the pivot type. | 8321 * supertype of the pivot type. |
| 8318 */ | 8322 */ |
| 8319 List<int> subclasses; | 8323 List<int> subclasses; |
| 8320 | 8324 |
| 8321 TypeHierarchyItem(this.classElement, this.interfaces, this.mixins, this.subcla
sses, {this.displayName, this.memberElement, this.superclass}); | 8325 TypeHierarchyItem(this.classElement, {this.displayName, this.memberElement, th
is.superclass, this.interfaces, this.mixins, this.subclasses}) { |
| 8326 if (interfaces == null) { |
| 8327 interfaces = <int>[]; |
| 8328 } |
| 8329 if (mixins == null) { |
| 8330 mixins = <int>[]; |
| 8331 } |
| 8332 if (subclasses == null) { |
| 8333 subclasses = <int>[]; |
| 8334 } |
| 8335 } |
| 8322 | 8336 |
| 8323 factory TypeHierarchyItem.fromJson(JsonDecoder jsonDecoder, String jsonPath, O
bject json) { | 8337 factory TypeHierarchyItem.fromJson(JsonDecoder jsonDecoder, String jsonPath, O
bject json) { |
| 8324 if (json == null) { | 8338 if (json == null) { |
| 8325 json = {}; | 8339 json = {}; |
| 8326 } | 8340 } |
| 8327 if (json is Map) { | 8341 if (json is Map) { |
| 8328 Element classElement; | 8342 Element classElement; |
| 8329 if (json.containsKey("classElement")) { | 8343 if (json.containsKey("classElement")) { |
| 8330 classElement = new Element.fromJson(jsonDecoder, jsonPath + ".classEleme
nt", json["classElement"]); | 8344 classElement = new Element.fromJson(jsonDecoder, jsonPath + ".classEleme
nt", json["classElement"]); |
| 8331 } else { | 8345 } else { |
| (...skipping 22 matching lines...) Expand all Loading... |
| 8354 mixins = jsonDecoder._decodeList(jsonPath + ".mixins", json["mixins"], j
sonDecoder._decodeInt); | 8368 mixins = jsonDecoder._decodeList(jsonPath + ".mixins", json["mixins"], j
sonDecoder._decodeInt); |
| 8355 } else { | 8369 } else { |
| 8356 throw jsonDecoder.missingKey(jsonPath, "mixins"); | 8370 throw jsonDecoder.missingKey(jsonPath, "mixins"); |
| 8357 } | 8371 } |
| 8358 List<int> subclasses; | 8372 List<int> subclasses; |
| 8359 if (json.containsKey("subclasses")) { | 8373 if (json.containsKey("subclasses")) { |
| 8360 subclasses = jsonDecoder._decodeList(jsonPath + ".subclasses", json["sub
classes"], jsonDecoder._decodeInt); | 8374 subclasses = jsonDecoder._decodeList(jsonPath + ".subclasses", json["sub
classes"], jsonDecoder._decodeInt); |
| 8361 } else { | 8375 } else { |
| 8362 throw jsonDecoder.missingKey(jsonPath, "subclasses"); | 8376 throw jsonDecoder.missingKey(jsonPath, "subclasses"); |
| 8363 } | 8377 } |
| 8364 return new TypeHierarchyItem(classElement, interfaces, mixins, subclasses,
displayName: displayName, memberElement: memberElement, superclass: superclass)
; | 8378 return new TypeHierarchyItem(classElement, displayName: displayName, membe
rElement: memberElement, superclass: superclass, interfaces: interfaces, mixins:
mixins, subclasses: subclasses); |
| 8365 } else { | 8379 } else { |
| 8366 throw jsonDecoder.mismatch(jsonPath, "TypeHierarchyItem"); | 8380 throw jsonDecoder.mismatch(jsonPath, "TypeHierarchyItem"); |
| 8367 } | 8381 } |
| 8368 } | 8382 } |
| 8369 | 8383 |
| 8370 Map<String, dynamic> toJson() { | 8384 Map<String, dynamic> toJson() { |
| 8371 Map<String, dynamic> result = {}; | 8385 Map<String, dynamic> result = {}; |
| 8372 result["classElement"] = classElement.toJson(); | 8386 result["classElement"] = classElement.toJson(); |
| 8373 if (displayName != null) { | 8387 if (displayName != null) { |
| 8374 result["displayName"] = displayName; | 8388 result["displayName"] = displayName; |
| (...skipping 749 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 9124 return false; | 9138 return false; |
| 9125 } | 9139 } |
| 9126 | 9140 |
| 9127 @override | 9141 @override |
| 9128 int get hashCode { | 9142 int get hashCode { |
| 9129 int hash = 0; | 9143 int hash = 0; |
| 9130 hash = _JenkinsSmiHash.combine(hash, newName.hashCode); | 9144 hash = _JenkinsSmiHash.combine(hash, newName.hashCode); |
| 9131 return _JenkinsSmiHash.finish(hash); | 9145 return _JenkinsSmiHash.finish(hash); |
| 9132 } | 9146 } |
| 9133 } | 9147 } |
| OLD | NEW |