generateForClass abstract method

dynamic generateForClass(
  1. BuildStep buildStep,
  2. ClassElement element,
  3. ElementAnnotation annotation
)

Generates code for an annotated class element.

This is called for each class in the library that has the annotation this generator is targeting.

@param buildStep The build step providing context for generation @param element The annotated class element @param annotation The annotation instance on the class @return Generated code as a string, or null if nothing to generate

Implementation

dynamic generateForClass(
  BuildStep buildStep,
  ClassElement element,
  ElementAnnotation annotation,
);