Class GeneratedTemplate

    • Field Detail

      • templateMetaModel

        protected final MetaModel templateMetaModel
      • ignoredInstructions

        protected java.util.Set<java.lang.String> ignoredInstructions
    • Constructor Detail

      • GeneratedTemplate

        public GeneratedTemplate​(MetaModel metaModel,
                                 TemplatePrinter printer,
                                 java.util.Set<java.lang.String> ignoredInstructions)
        Constructs a template generator.
        Parameters:
        metaModel - model of the microprocessor.
        printer - printer for the template.
        ignoredInstructions - instructions to ignore.
      • GeneratedTemplate

        public GeneratedTemplate​(MetaModel metaModel,
                                 TemplatePrinter printer)
        Constructs a template generator. There are no instructions to ignore.
        Parameters:
        metaModel - model of the microprocessor.
        printer - printer for the template.
    • Method Detail

      • generate

        public abstract boolean generate()
        Generates the template and output it in the format of the specified printer.
        Specified by:
        generate in interface BaseTemplate
      • extract

        protected abstract boolean extract()
        Extracts the information from model for this template.
        Returns:
        true if success
      • sort

        public void sort()
        Sorts instructions by groups.