| 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 // For the purposes of the mirrors library, we adopt a naming | 5 // For the purposes of the mirrors library, we adopt a naming |
| 6 // convention with respect to getters and setters. Specifically, for | 6 // convention with respect to getters and setters. Specifically, for |
| 7 // some variable or field... | 7 // some variable or field... |
| 8 // | 8 // |
| 9 // var myField; | 9 // var myField; |
| 10 // | 10 // |
| (...skipping 268 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 279 | 279 |
| 280 /** | 280 /** |
| 281 * Is this declaration top-level? | 281 * Is this declaration top-level? |
| 282 * | 282 * |
| 283 * This is defined to be equivalent to: | 283 * This is defined to be equivalent to: |
| 284 * [:mirror.owner != null && mirror.owner is LibraryMirror:] | 284 * [:mirror.owner != null && mirror.owner is LibraryMirror:] |
| 285 */ | 285 */ |
| 286 bool get isTopLevel; | 286 bool get isTopLevel; |
| 287 | 287 |
| 288 /** | 288 /** |
| 289 * The source location of this Dart language entity. | 289 * The source location of this Dart language entity, or [:null:] if the |
| 290 * entity is synthetic. |
| 290 * | 291 * |
| 291 * This operation is optional and may return [:null:]. | 292 * If the reflectee is a variable, the returned location gives the position of
* the variable name at its point of declaration. |
| 293 * |
| 294 * If the reflectee is a library, class, typedef, function or type variable |
| 295 * with associated metadata, the returned location gives the position of the |
| 296 * first metadata declaration associated with the reflectee. |
| 297 * |
| 298 * Otherwise: |
| 299 * If the reflectee is a library, the returned location gives the position of |
| 300 * the keyword 'library' at the reflectee's point of declaration, if the |
| 301 * reflectee is a named library, or the first character of the first line in |
| 302 * the compilation unit defining the reflectee if the reflectee is anonymous. |
| 303 * |
| 304 * If the reflectee is an abstract class, the returned location gives the |
| 305 * position of the keyword 'abstract' at the reflectee's point of declaration.
* Otherwise, if the reflectee is a class, the returned location gives the |
| 306 * position of the keyword 'class' at the reflectee's point of declaration. |
| 307 * |
| 308 * If the reflectee is a typedef the returned location gives the position of |
| 309 * the of the keyword 'typedef' at the reflectee's point of declaration. |
| 310 * |
| 311 * If the reflectee is a function with a declared return type, the returned |
| 312 * location gives the position of the function's return type at the |
| 313 * reflectee's point of declaration. Otherwise. the returned location gives |
| 314 * the position of the function's name at the reflectee's point of |
| 315 * declaration. |
| 316 * |
| 317 * This operation is optional and may throw an [UnsupportedError]. |
| 292 */ | 318 */ |
| 293 SourceLocation get location; | 319 SourceLocation get location; |
| 294 | 320 |
| 295 /** | 321 /** |
| 296 * A list of the metadata associated with this declaration. | 322 * A list of the metadata associated with this declaration. |
| 297 * | 323 * |
| 298 * Let *D* be the declaration this mirror reflects. | 324 * Let *D* be the declaration this mirror reflects. |
| 299 * If *D* is decorated with annotations *A1, ..., An* | 325 * If *D* is decorated with annotations *A1, ..., An* |
| 300 * where *n > 0*, then for each annotation *Ai* associated | 326 * where *n > 0*, then for each annotation *Ai* associated |
| 301 * with *D, 1 <= i <= n*, let *ci* be the constant object | 327 * with *D, 1 <= i <= n*, let *ci* be the constant object |
| (...skipping 924 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1226 * | 1252 * |
| 1227 * When used as metadata on an import of "dart:mirrors", this metadata does | 1253 * When used as metadata on an import of "dart:mirrors", this metadata does |
| 1228 * not apply to the library in which the annotation is used, but instead | 1254 * not apply to the library in which the annotation is used, but instead |
| 1229 * applies to the other libraries (all libraries if "*" is used). | 1255 * applies to the other libraries (all libraries if "*" is used). |
| 1230 */ | 1256 */ |
| 1231 final override; | 1257 final override; |
| 1232 | 1258 |
| 1233 const MirrorsUsed( | 1259 const MirrorsUsed( |
| 1234 {this.symbols, this.targets, this.metaTargets, this.override}); | 1260 {this.symbols, this.targets, this.metaTargets, this.override}); |
| 1235 } | 1261 } |
| OLD | NEW |