| OLD | NEW |
| 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, 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 part of dart2js.mirrors; | 5 part of dart2js.mirrors; |
| 6 | 6 |
| 7 | 7 |
| 8 class Dart2JsLibraryMirror | 8 class Dart2JsLibraryMirror |
| 9 extends Dart2JsElementMirror | 9 extends Dart2JsElementMirror |
| 10 with ObjectMirrorMixin, ContainerMixin | 10 with ObjectMirrorMixin, ContainerMixin |
| (...skipping 136 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 147 if (import != null && import.prefix != null) { | 147 if (import != null && import.prefix != null) { |
| 148 return import.prefix.source; | 148 return import.prefix.source; |
| 149 } | 149 } |
| 150 return null; | 150 return null; |
| 151 } | 151 } |
| 152 | 152 |
| 153 bool get isImport => _node.asImport() != null; | 153 bool get isImport => _node.asImport() != null; |
| 154 | 154 |
| 155 bool get isExport => _node.asExport() != null; | 155 bool get isExport => _node.asExport() != null; |
| 156 | 156 |
| 157 bool get isDeferred { |
| 158 if (_node is Import) { |
| 159 Import import = _node; |
| 160 return import.isDeferred; |
| 161 } |
| 162 return false; |
| 163 } |
| 164 |
| 157 List<InstanceMirror> get metadata => const <InstanceMirror>[]; | 165 List<InstanceMirror> get metadata => const <InstanceMirror>[]; |
| 158 } | 166 } |
| 159 | 167 |
| 160 class Dart2JsCombinatorMirror implements CombinatorSourceMirror { | 168 class Dart2JsCombinatorMirror implements CombinatorSourceMirror { |
| 161 final List/*<String>*/ identifiers; | 169 final List/*<String>*/ identifiers; |
| 162 final bool isShow; | 170 final bool isShow; |
| 163 | 171 |
| 164 Dart2JsCombinatorMirror(this.identifiers, {bool isShow: true}) | 172 Dart2JsCombinatorMirror(this.identifiers, {bool isShow: true}) |
| 165 : this.isShow = isShow; | 173 : this.isShow = isShow; |
| 166 | 174 |
| (...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 227 int get offset => _span.begin; | 235 int get offset => _span.begin; |
| 228 | 236 |
| 229 int get length => _span.end - _span.begin; | 237 int get length => _span.end - _span.begin; |
| 230 | 238 |
| 231 String get text => _script.text.substring(_span.begin, _span.end); | 239 String get text => _script.text.substring(_span.begin, _span.end); |
| 232 | 240 |
| 233 Uri get sourceUri => _script.resourceUri; | 241 Uri get sourceUri => _script.resourceUri; |
| 234 | 242 |
| 235 String get sourceText => _script.text; | 243 String get sourceText => _script.text; |
| 236 } | 244 } |
| OLD | NEW |