EnumDefinition class

Parsed enum declaration.

Annotations
  • @immutable

Constructors

EnumDefinition({required String name, required List<String> values, List<ModelAttribute> attributes = const <ModelAttribute>[], int? line, int? column})
Creates an enum definition.
const

Properties

attributes List<ModelAttribute>
Enum-level attributes such as @@map.
final
column int?
One-based source column where the enum block starts, if known.
final
databaseName String
Database type name after applying @@map, if present.
no setter
hashCode int
The hash code for this object.
no setterinherited
line int?
One-based source line where the enum block starts, if known.
final
name String
Enum name.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
values List<String>
Enum values in source order.
final

Methods

attribute(String name) ModelAttribute?
Finds the first enum-level attribute named name.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited