Whether the element has an annotation of the form @factory.
@factory
@override bool get hasFactory => metadata.any((ElementAnnotation m) => m.isFactory);