enumDeclaration abstract method

EnumDeclaration enumDeclaration(
  1. Comment? comment,
  2. List<Annotation>? metadata,
  3. Token enumKeyword,
  4. SimpleIdentifier name,
  5. Token leftBracket,
  6. List<EnumConstantDeclaration> constants,
  7. Token rightBracket,
)

Returns a newly created enumeration declaration. Either or both of the comment and metadata can be null if the declaration does not have the corresponding attribute. The list of constants must contain at least one value.

Implementation

EnumDeclaration enumDeclaration(
    Comment? comment,
    List<Annotation>? metadata,
    Token enumKeyword,
    SimpleIdentifier name,
    Token leftBracket,
    List<EnumConstantDeclaration> constants,
    Token rightBracket);