hasDomName function
bool hasDomName(Source
bool hasDomName(mirrors.DeclarationMirror mirror) { var location = mirror.location; if (location == null || location.sourceUri.scheme != 'dart') return false; for (var annotation in mirror.metadata) { if (mirrors.MirrorSystem.getName(annotation.type.simpleName) == "DomName") { // We can't make sure the annotation is in dart: as Dartium believes it // is file://dart/sdk/lib/html/html_common/metadata.dart // instead of a proper dart: location. return true; } } return false; }
© 2012 the Dart project authors
Licensed under the Creative Commons Attribution-ShareAlike License v4.0.
https://api.dartlang.org/stable/1.24.3/dart-js/hasDomName.html