| OLD | NEW |
| 1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2015, 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 "pkg/analyzer/tool/generate_files". | 6 // To regenerate the file, use the script "pkg/analyzer/tool/generate_files". |
| 7 | 7 |
| 8 library analyzer.src.summary.format; | 8 library analyzer.src.summary.format; |
| 9 | 9 |
| 10 import 'base.dart' as base; | 10 import 'base.dart' as base; |
| (...skipping 27 matching lines...) Expand all Loading... |
| 38 enum UnlinkedParamKind { | 38 enum UnlinkedParamKind { |
| 39 required, | 39 required, |
| 40 positional, | 40 positional, |
| 41 named, | 41 named, |
| 42 } | 42 } |
| 43 | 43 |
| 44 class PrelinkedDependencyBuilder { | 44 class PrelinkedDependencyBuilder { |
| 45 bool _finished = false; | 45 bool _finished = false; |
| 46 | 46 |
| 47 String _uri; | 47 String _uri; |
| 48 List<String> _parts; |
| 48 | 49 |
| 49 PrelinkedDependencyBuilder(); | 50 PrelinkedDependencyBuilder(); |
| 50 | 51 |
| 51 /** | 52 /** |
| 52 * The relative URI used to import one library from the other. | 53 * The relative URI of the dependent library. This URI is relative to the |
| 54 * importing library, even if there are intervening `export` declarations. |
| 55 * So, for example, if `a.dart` imports `b/c.dart` and `b/c.dart` exports |
| 56 * `d/e.dart`, the URI listed for `a.dart`'s dependency on `e.dart` will be |
| 57 * `b/d/e.dart`. |
| 53 */ | 58 */ |
| 54 void set uri(String _value) { | 59 void set uri(String _value) { |
| 55 assert(!_finished); | 60 assert(!_finished); |
| 56 _uri = _value; | 61 _uri = _value; |
| 57 } | 62 } |
| 58 | 63 |
| 64 /** |
| 65 * URI for the compilation units listed in the library's `part` declarations. |
| 66 * These URIs are relative to the importing library. |
| 67 */ |
| 68 void set parts(List<String> _value) { |
| 69 assert(!_finished); |
| 70 _parts = _value; |
| 71 } |
| 72 |
| 59 fb.Offset finish(fb.Builder fbBuilder) { | 73 fb.Offset finish(fb.Builder fbBuilder) { |
| 60 assert(!_finished); | 74 assert(!_finished); |
| 61 _finished = true; | 75 _finished = true; |
| 62 fb.Offset offset_uri; | 76 fb.Offset offset_uri; |
| 77 fb.Offset offset_parts; |
| 63 if (_uri != null) { | 78 if (_uri != null) { |
| 64 offset_uri = fbBuilder.writeString(_uri); | 79 offset_uri = fbBuilder.writeString(_uri); |
| 65 } | 80 } |
| 81 if (!(_parts == null || _parts.isEmpty)) { |
| 82 offset_parts = fbBuilder.writeList(_parts.map((b) => fbBuilder.writeString
(b)).toList()); |
| 83 } |
| 66 fbBuilder.startTable(); | 84 fbBuilder.startTable(); |
| 67 if (offset_uri != null) { | 85 if (offset_uri != null) { |
| 68 fbBuilder.addOffset(0, offset_uri); | 86 fbBuilder.addOffset(0, offset_uri); |
| 69 } | 87 } |
| 88 if (offset_parts != null) { |
| 89 fbBuilder.addOffset(1, offset_parts); |
| 90 } |
| 70 return fbBuilder.endTable(); | 91 return fbBuilder.endTable(); |
| 71 } | 92 } |
| 72 } | 93 } |
| 73 | 94 |
| 74 PrelinkedDependencyBuilder encodePrelinkedDependency({String uri}) { | 95 PrelinkedDependencyBuilder encodePrelinkedDependency({String uri, List<String> p
arts}) { |
| 75 PrelinkedDependencyBuilder builder = new PrelinkedDependencyBuilder(); | 96 PrelinkedDependencyBuilder builder = new PrelinkedDependencyBuilder(); |
| 76 builder.uri = uri; | 97 builder.uri = uri; |
| 98 builder.parts = parts; |
| 77 return builder; | 99 return builder; |
| 78 } | 100 } |
| 79 | 101 |
| 80 /** | 102 /** |
| 81 * Information about a dependency that exists between one library and another | 103 * Information about a dependency that exists between one library and another |
| 82 * due to an "import" declaration. | 104 * due to an "import" declaration. |
| 83 */ | 105 */ |
| 84 abstract class PrelinkedDependency extends base.SummaryClass { | 106 abstract class PrelinkedDependency extends base.SummaryClass { |
| 85 | 107 |
| 86 /** | 108 /** |
| 87 * The relative URI used to import one library from the other. | 109 * The relative URI of the dependent library. This URI is relative to the |
| 110 * importing library, even if there are intervening `export` declarations. |
| 111 * So, for example, if `a.dart` imports `b/c.dart` and `b/c.dart` exports |
| 112 * `d/e.dart`, the URI listed for `a.dart`'s dependency on `e.dart` will be |
| 113 * `b/d/e.dart`. |
| 88 */ | 114 */ |
| 89 String get uri; | 115 String get uri; |
| 116 |
| 117 /** |
| 118 * URI for the compilation units listed in the library's `part` declarations. |
| 119 * These URIs are relative to the importing library. |
| 120 */ |
| 121 List<String> get parts; |
| 90 } | 122 } |
| 91 | 123 |
| 92 class _PrelinkedDependencyReader extends fb.TableReader<_PrelinkedDependencyImpl
> { | 124 class _PrelinkedDependencyReader extends fb.TableReader<_PrelinkedDependencyImpl
> { |
| 93 const _PrelinkedDependencyReader(); | 125 const _PrelinkedDependencyReader(); |
| 94 | 126 |
| 95 @override | 127 @override |
| 96 _PrelinkedDependencyImpl createObject(fb.BufferPointer bp) => new _PrelinkedDe
pendencyImpl(bp); | 128 _PrelinkedDependencyImpl createObject(fb.BufferPointer bp) => new _PrelinkedDe
pendencyImpl(bp); |
| 97 } | 129 } |
| 98 | 130 |
| 99 class _PrelinkedDependencyImpl implements PrelinkedDependency { | 131 class _PrelinkedDependencyImpl implements PrelinkedDependency { |
| 100 final fb.BufferPointer _bp; | 132 final fb.BufferPointer _bp; |
| 101 | 133 |
| 102 _PrelinkedDependencyImpl(this._bp); | 134 _PrelinkedDependencyImpl(this._bp); |
| 103 | 135 |
| 104 String _uri; | 136 String _uri; |
| 137 List<String> _parts; |
| 105 | 138 |
| 106 @override | 139 @override |
| 107 Map<String, Object> toMap() => { | 140 Map<String, Object> toMap() => { |
| 108 "uri": uri, | 141 "uri": uri, |
| 142 "parts": parts, |
| 109 }; | 143 }; |
| 110 | 144 |
| 111 @override | 145 @override |
| 112 String get uri { | 146 String get uri { |
| 113 _uri ??= const fb.StringReader().vTableGet(_bp, 0, ''); | 147 _uri ??= const fb.StringReader().vTableGet(_bp, 0, ''); |
| 114 return _uri; | 148 return _uri; |
| 115 } | 149 } |
| 150 |
| 151 @override |
| 152 List<String> get parts { |
| 153 _parts ??= const fb.ListReader<String>(const fb.StringReader()).vTableGet(_b
p, 1, const <String>[]); |
| 154 return _parts; |
| 155 } |
| 116 } | 156 } |
| 117 | 157 |
| 118 class PrelinkedLibraryBuilder { | 158 class PrelinkedLibraryBuilder { |
| 119 bool _finished = false; | 159 bool _finished = false; |
| 120 | 160 |
| 121 List<PrelinkedUnitBuilder> _units; | 161 List<PrelinkedUnitBuilder> _units; |
| 122 List<PrelinkedDependencyBuilder> _dependencies; | 162 List<PrelinkedDependencyBuilder> _dependencies; |
| 123 List<int> _importDependencies; | 163 List<int> _importDependencies; |
| 124 | 164 |
| 125 PrelinkedLibraryBuilder(); | 165 PrelinkedLibraryBuilder(); |
| (...skipping 4497 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4623 return _isConst; | 4663 return _isConst; |
| 4624 } | 4664 } |
| 4625 | 4665 |
| 4626 @override | 4666 @override |
| 4627 bool get hasImplicitType { | 4667 bool get hasImplicitType { |
| 4628 _hasImplicitType ??= const fb.BoolReader().vTableGet(_bp, 7, false); | 4668 _hasImplicitType ??= const fb.BoolReader().vTableGet(_bp, 7, false); |
| 4629 return _hasImplicitType; | 4669 return _hasImplicitType; |
| 4630 } | 4670 } |
| 4631 } | 4671 } |
| 4632 | 4672 |
| OLD | NEW |