![]() |
lingua-franca 0.10.1
Lingua Franca code generator
|
The context of a Lingua Franca build process. More...
Inherits IGeneratorContext.
Inherited by org.lflang.generator.MainContext, and org.lflang.generator.SubContext.
Classes | |
| enum | Mode |
Public Member Functions | |
| void | finish (GeneratorResult result) |
| Mark the code generation process performed in this context as finished with the result result. | |
| default void | finish (GeneratorResult.Status status, Map< Path, CodeMap > codeMaps) |
| Conclude this build and record the result if necessary. | |
| GeneratorArguments | getArgs () |
| Return any arguments that will override target properties. | |
| MessageReporter | getErrorReporter () |
| Get the error reporter for this context; construct one if it hasn't been constructed yet. | |
| FileConfig | getFileConfig () |
| Mode | getMode () |
| Return the mode of operation, which indicates how the compiler has been invoked (e.g., from within Epoch, from the command line, or via a Language Server). | |
| GeneratorResult | getResult () |
| Return the result of the code generation process that was performed in this context. | |
| TargetConfig | getTargetConfig () |
| default boolean | isCleanRequested () |
| Return true if the user requested a clean build in this context. | |
| void | reportProgress (String message, int percentage) |
| Report the progress of a build. | |
| default void | unsuccessfulFinish () |
| Conclude this build and record that it was unsuccessful. | |
Static Public Member Functions | |
| static LFGeneratorContext | lfGeneratorContextOf (Resource resource, IFileSystemAccess2 fsa, IGeneratorContext context) |
| Return the LFGeneratorContext that best describes the given context when building Resource. | |
The context of a Lingua Franca build process.
It is the point of communication between a build process and the environment in which it is executed.
| void org.lflang.generator.LFGeneratorContext.finish | ( | GeneratorResult | result | ) |
Mark the code generation process performed in this context as finished with the result result.
| result | The result of the code generation process that was performed in this context. |
Implemented in org.lflang.generator.MainContext, and org.lflang.generator.SubContext.
| default void org.lflang.generator.LFGeneratorContext.finish | ( | GeneratorResult.Status | status, |
| Map< Path, CodeMap > | codeMaps ) |
Conclude this build and record the result if necessary.
| status | The status of the result. |
| codeMaps | The generated files and their corresponding code maps. |
| GeneratorArguments org.lflang.generator.LFGeneratorContext.getArgs | ( | ) |
Return any arguments that will override target properties.
Implemented in org.lflang.generator.MainContext, and org.lflang.generator.SubContext.
| MessageReporter org.lflang.generator.LFGeneratorContext.getErrorReporter | ( | ) |
Get the error reporter for this context; construct one if it hasn't been constructed yet.
Implemented in org.lflang.generator.MainContext, and org.lflang.generator.SubContext.
| FileConfig org.lflang.generator.LFGeneratorContext.getFileConfig | ( | ) |
Implemented in org.lflang.generator.MainContext, and org.lflang.generator.SubContext.
| Mode org.lflang.generator.LFGeneratorContext.getMode | ( | ) |
Return the mode of operation, which indicates how the compiler has been invoked (e.g., from within Epoch, from the command line, or via a Language Server).
Implemented in org.lflang.generator.MainContext, and org.lflang.generator.SubContext.
| GeneratorResult org.lflang.generator.LFGeneratorContext.getResult | ( | ) |
Return the result of the code generation process that was performed in this context.
Implemented in org.lflang.generator.MainContext, and org.lflang.generator.SubContext.
| TargetConfig org.lflang.generator.LFGeneratorContext.getTargetConfig | ( | ) |
Implemented in org.lflang.generator.MainContext, and org.lflang.generator.SubContext.
| default boolean org.lflang.generator.LFGeneratorContext.isCleanRequested | ( | ) |
Return true if the user requested a clean build in this context.
Implemented in org.lflang.generator.SubContext.
|
static |
Return the LFGeneratorContext that best describes the given context when building Resource.
| resource | |
| fsa | |
| context | The context of a Lingua Franca build process. |
| void org.lflang.generator.LFGeneratorContext.reportProgress | ( | String | message, |
| int | percentage ) |
Report the progress of a build.
| message | A message for the LF programmer to read. |
| percentage | The approximate percent completion of the build. |
Implemented in org.lflang.generator.MainContext, and org.lflang.generator.SubContext.
| default void org.lflang.generator.LFGeneratorContext.unsuccessfulFinish | ( | ) |
Conclude this build and record that it was unsuccessful.