annotation abstract method

Annotation annotation({
  1. required Token atSign,
  2. required Identifier name,
  3. TypeArgumentList? typeArguments,
  4. Token? period,
  5. SimpleIdentifier? constructorName,
  6. ArgumentList? arguments,
})

Returns a newly created annotation. Both the period and the constructorName can be null if the annotation is not referencing a named constructor. The arguments can be null if the annotation is not referencing a constructor.

Note that type arguments are only valid if Feature.generic_metadata is enabled.

Implementation

Annotation annotation(
    {required Token atSign,
    required Identifier name,
    TypeArgumentList? typeArguments,
    Token? period,
    SimpleIdentifier? constructorName,
    ArgumentList? arguments});