classFilePathsFromAnnotations static method
Implementation
static Map<String, String> classFilePathsFromAnnotations(
Iterable<AnnotatedElement> annotations,
Map<String, String> filesToContents,
) {
return {
for (final annotation in annotations)
'${annotation.element.name}': filesToContents.entries
.firstWhere((entry) => entry.value.contains('class ${annotation.element.name} '))
.key
// Make relative from the `brick/` folder
.replaceAll(RegExp('^lib/'), '../'),
};
}