visitEnumDecl method

  1. @override
String visitEnumDecl(
  1. EnumDecl stmt
)
override

Implementation

@override
String visitEnumDecl(EnumDecl stmt) {
  final output = StringBuffer();
  if (stmt.isExternal) {
    output.write('${_lexicon.kExternal} ');
  }
  output
      .writeln('${_lexicon.kEnum} ${stmt.id.id} ${_lexicon.codeBlockStart}');
  ++_curIndentCount;
  output.write(stmt.enumerations.join('${_lexicon.comma}\n'));
  output.writeln();
  --_curIndentCount;
  output.write(curIndent);
  output.write(_lexicon.codeBlockEnd);
  return output.toString();
}