getClasses function

List<ClassDeclaration> getClasses(
  1. CompilationUnit code
)

Implementation

List<ClassDeclaration> getClasses(CompilationUnit code) {
  return code.childEntities
      .whereType<ClassDeclaration>()
      .toList()
      .cast<ClassDeclaration>();
}