Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 library docgen.moedls; | |
|
Alan Knight
2014/03/12 18:17:56
typo
kevmoo
2014/03/17 02:01:29
Done.
| |
| 2 | |
| 3 import '../../../../sdk/lib/_internal/compiler/implementation/mirrors/source_mir rors.dart'; | |
| 4 import '../../../../sdk/lib/_internal/compiler/implementation/mirrors/mirrors_ut il.dart' | |
| 5 as dart2js_util; | |
| 6 | |
| 7 /// Docgen representation of an item to be documented, that wraps around a | |
| 8 /// dart2js mirror. | |
| 9 abstract class MirrorBased { | |
| 10 /// The original dart2js mirror around which this object wraps. | |
| 11 DeclarationMirror get mirror; | |
| 12 } | |
| 13 | |
| 14 /// A Docgen wrapper around the dart2js mirror for a generic type. | |
| 15 class Generic extends MirrorBased { | |
| 16 final TypeVariableMirror mirror; | |
| 17 | |
| 18 Generic(this.mirror); | |
| 19 | |
| 20 Map toMap() => { | |
| 21 'name': dart2js_util.nameOf(mirror), | |
| 22 'type': dart2js_util.qualifiedNameOf(mirror.upperBound) | |
| 23 }; | |
| 24 } | |
|
Emily Fortuna
2014/03/06 22:05:38
what about putting Type and Parameter here, too? T
kevmoo
2014/03/06 22:20:17
I wish, but there is a lot of dependency spaghetti
| |
| OLD | NEW |