-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Plugin Pipeline
Jesse Talavera-Greenberg edited this page May 6, 2019
·
2 revisions
The code generator system works as a pipeline that runs the following steps:
-
Configuration: Read all configuration options from the
.properties
files in your project's root directory, and configure all plugins accordingly. -
Pre-Processing: Pre-process your code or environment, via plugins that implement
IPreProcessor
. - Parsing and Caching: Parse your project's code into a format that the rest of your plugins can use.
-
Data Extraction: Extract whatever data you want from your project and store it in a big array for use by code generators. The extraction is done by plugins that implement
IDataProvider
, and is stored in an array of instances or subclasses ofCodeGeneratorData
. -
Code Generation: The code is generated by any plugin that implements
ICodeGenerator
, and stored in instances ofCodeGenFile
. ACodeGeneratorData[]
containing all data from allIDataProvider
s is made available for use as you see fit. -
Post-Processing: The generated code is post-processed by all plugins that implement
IPostProcessor
. The previously-generatedCodeGenFile
s are made available to post-processors and can be manipulated freely. - Using Generated Code: Your code is now ready for use!
These stages are run in sequence, and each plugin within a stage is run in sequence. However, an individual plugin can process data in parallel if you'd like.
Each page describes a stage of the pipeline in detail.
Guides: Introduction - Installation - Upgrading - FAQ - Cookbook - Contributing
Need Help? Ask a question on Discord or create an issue.
- The Basics
- Concepts
- Architecture / Patterns