Package org.apache.camel.maven.packaging
Class PrepareCamelMainMojo
- java.lang.Object
-
- org.apache.maven.plugin.AbstractMojo
-
- org.apache.camel.maven.packaging.AbstractGeneratorMojo
-
- org.apache.camel.maven.packaging.PrepareCamelMainMojo
-
- All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled
,org.apache.maven.plugin.Mojo
@Mojo(name="prepare-main-doc", defaultPhase=PROCESS_CLASSES, threadSafe=true, requiresDependencyResolution=COMPILE) public class PrepareCamelMainMojo extends AbstractGeneratorMojo
Prepares camel-main by generating Camel Main configuration metadata for tooling support.
-
-
Field Summary
Fields Modifier and Type Field Description protected File
outFolder
The output directory for generated spring boot tooling file-
Fields inherited from class org.apache.camel.maven.packaging.AbstractGeneratorMojo
buildContext, GENERATED_MSG, NL, project, projectHelper
-
-
Constructor Summary
Constructors Constructor Description PrepareCamelMainMojo()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
execute()
void
execute(org.apache.maven.project.MavenProject project, org.apache.maven.project.MavenProjectHelper projectHelper, org.sonatype.plexus.build.incremental.BuildContext buildContext)
static List<org.apache.camel.tooling.model.MainModel.MainOptionModel>
parseConfigurationSource(File file)
Parses the Camel Main configuration java source file.static List<org.apache.camel.tooling.model.MainModel.MainOptionModel>
parseConfigurationSource(String fileName)
Parses the Camel Main configuration java source file.-
Methods inherited from class org.apache.camel.maven.packaging.AbstractGeneratorMojo
addResourceDirectory, cache, createProperties, createProperties, getProjectClassLoader, haveResourcesChanged, loadClass, refresh, refresh, updateResource, updateResource
-
-
-
-
Field Detail
-
outFolder
@Parameter(defaultValue="${project.basedir}/src/main/doc") protected File outFolder
The output directory for generated spring boot tooling file
-
-
Method Detail
-
parseConfigurationSource
public static List<org.apache.camel.tooling.model.MainModel.MainOptionModel> parseConfigurationSource(String fileName) throws IOException
Parses the Camel Main configuration java source file.- Throws:
IOException
-
parseConfigurationSource
public static List<org.apache.camel.tooling.model.MainModel.MainOptionModel> parseConfigurationSource(File file) throws IOException
Parses the Camel Main configuration java source file.- Throws:
IOException
-
execute
public void execute(org.apache.maven.project.MavenProject project, org.apache.maven.project.MavenProjectHelper projectHelper, org.sonatype.plexus.build.incremental.BuildContext buildContext) throws org.apache.maven.plugin.MojoFailureException, org.apache.maven.plugin.MojoExecutionException
- Overrides:
execute
in classAbstractGeneratorMojo
- Throws:
org.apache.maven.plugin.MojoFailureException
org.apache.maven.plugin.MojoExecutionException
-
execute
public void execute() throws org.apache.maven.plugin.MojoExecutionException, org.apache.maven.plugin.MojoFailureException
- Throws:
org.apache.maven.plugin.MojoExecutionException
org.apache.maven.plugin.MojoFailureException
-
-