Class Compiler.Phase_enum

All Implemented Interfaces:
PCDataVisitor
Enclosing class:
Compiler

protected class Compiler.Phase_enum extends Visitor
Zeroth phase, collect and generate code for enumerations. glo out enums, enumsWithDocText, enumsWithItemDocText, enumClasses.
  • Field Details

    • sb

      Lives during the visit of one enumeration and collects the lines user infos.
    • currentEnum

      GeneratedClass currentEnum
      Class generated for the enumeration currently under visit.
    • currentEnumItemName

      @Opt @Opt String currentEnumItemName
      When visiting an Element_desc: Name of the containing enumeration item. or null if desc belongs to enumeration itself.
  • Constructor Details

    • Phase_enum

      protected Phase_enum()
  • Method Details

    • visit

      public void visit(Element_enumeration element)
      Analyse the visited enumeration and descend into its sub-elements. Collect payload-level user information and add comments to the generated objects and to the usage() code.
      Overrides:
      visit in class Visitor
    • visit

      public void visit(Element_option element)
      Do NOT descend!
      Overrides:
      visit in class Visitor
    • visit

      public void visit(Element_comment element)
      Do NOT descend!
      Overrides:
      visit in class Visitor
    • visit

      public void visit(Element_printout_title element)
      Do NOT descend!
      Overrides:
      visit in class Visitor
    • visit

      public void visit(Element_text el)
      Memorize description text for gui tool-tips. Element_comment, Element_option etc. are ALL skipped, Visitor comes here only from Element_enumeration or Element_enum_item
      Overrides:
      visit in class Visitor