Package org.apache.camel.maven.packaging
Class PrepareCamelJBangMojo
java.lang.Object
org.apache.maven.plugin.AbstractMojo
org.apache.camel.maven.packaging.AbstractGeneratorMojo
org.apache.camel.maven.packaging.PrepareCamelJBangMojo
- All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled,org.apache.maven.plugin.Mojo
@Mojo(name="prepare-jbang",
defaultPhase=PROCESS_CLASSES,
threadSafe=true,
requiresDependencyResolution=COMPILE)
public class PrepareCamelJBangMojo
extends AbstractGeneratorMojo
Prepares camel-jbang by generating Camel JBang configuration metadata for tooling support.
-
Field Summary
FieldsFields inherited from class org.apache.camel.maven.packaging.AbstractGeneratorMojo
buildContext, GENERATED_MSG, NL, project, projectHelperFields inherited from interface org.apache.maven.plugin.Mojo
ROLE -
Constructor Summary
ConstructorsConstructorDescriptionPrepareCamelJBangMojo(org.apache.maven.project.MavenProjectHelper projectHelper, org.codehaus.plexus.build.BuildContext buildContext) -
Method Summary
Modifier and TypeMethodDescriptionvoidexecute()voidexecute(org.apache.maven.project.MavenProject project) static List<org.apache.camel.tooling.model.JBangModel.JBangOptionModel> parseConfigurationSource(File file) Parses the Camel JBang configuration java source file.static List<org.apache.camel.tooling.model.JBangModel.JBangOptionModel> parseConfigurationSource(String fileName) Parses the Camel JBang configuration java source file.Methods inherited from class org.apache.camel.maven.packaging.AbstractGeneratorMojo
addResourceDirectory, cache, canonicalClassName, createProperties, createProperties, findConfigurations, format, getProjectClassLoader, haveResourcesChanged, isJsonFile, loadClass, newTreeMap, newTreeSet, refresh, refresh, updateResource, updateResource, velocityMethods inherited from class org.apache.maven.plugin.AbstractMojo
getLog, getPluginContext, setLog, setPluginContext
-
Field Details
-
outFolder
-
-
Constructor Details
-
PrepareCamelJBangMojo
@Inject public PrepareCamelJBangMojo(org.apache.maven.project.MavenProjectHelper projectHelper, org.codehaus.plexus.build.BuildContext buildContext)
-
-
Method Details
-
parseConfigurationSource
public static List<org.apache.camel.tooling.model.JBangModel.JBangOptionModel> parseConfigurationSource(String fileName) throws IOException Parses the Camel JBang configuration java source file.- Throws:
IOException
-
parseConfigurationSource
public static List<org.apache.camel.tooling.model.JBangModel.JBangOptionModel> parseConfigurationSource(File file) throws IOException Parses the Camel JBang configuration java source file.- Throws:
IOException
-
execute
public void execute(org.apache.maven.project.MavenProject project) throws org.apache.maven.plugin.MojoFailureException, org.apache.maven.plugin.MojoExecutionException - Overrides:
executein classAbstractGeneratorMojo- Throws:
org.apache.maven.plugin.MojoFailureExceptionorg.apache.maven.plugin.MojoExecutionException
-
execute
public void execute() throws org.apache.maven.plugin.MojoExecutionException, org.apache.maven.plugin.MojoFailureException- Throws:
org.apache.maven.plugin.MojoExecutionExceptionorg.apache.maven.plugin.MojoFailureException
-