Class GenerateMojo

java.lang.Object
org.apache.maven.plugin.AbstractMojo
org.codehaus.mojo.exec.AbstractExecMojo
org.apache.camel.maven.GenerateMojo
All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled, org.apache.maven.plugin.Mojo

@Mojo(name="generate", threadSafe=true, requiresDependencyResolution=COMPILE_PLUS_RUNTIME, defaultPhase=GENERATE_SOURCES) public class GenerateMojo extends org.codehaus.mojo.exec.AbstractExecMojo
Parses the source code and generates source code for the csimple language.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final String
     
    protected File
    The output directory for generated source files
    protected File
    The output directory for generated resources files
    protected org.apache.maven.project.MavenProject
    The maven project.
    static final String
     
    protected File
    The resources directory for configuration files

    Fields inherited from class org.codehaus.mojo.exec.AbstractExecMojo

    classpathScope, executableDependency

    Fields inherited from interface org.apache.maven.plugin.Mojo

    ROLE
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    protected void
    doExecuteRoutes(org.apache.camel.language.csimple.CSimpleCodeGenerator generator)
     
    void
     
    static boolean
     

    Methods inherited from class org.codehaus.mojo.exec.AbstractExecMojo

    collectProjectArtifactsAndClasspath, findExecutableArtifact, getPluginDependencies, getSession, hasCommandlineArgs, isSkip, parseCommandlineArgs, registerSourceRoots

    Methods inherited from class org.apache.maven.plugin.AbstractMojo

    getLog, getPluginContext, setLog, setPluginContext

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • GENERATED_MSG

      public static final String GENERATED_MSG
      See Also:
    • RESOURCE_FILE

      public static final String RESOURCE_FILE
      See Also:
    • project

      @Parameter(property="project", required=true, readonly=true) protected org.apache.maven.project.MavenProject project
      The maven project.
    • outputDir

      @Parameter(defaultValue="${project.basedir}/src/generated/java") protected File outputDir
      The output directory for generated source files
    • outputResourceDir

      @Parameter(defaultValue="${project.basedir}/src/generated/resources") protected File outputResourceDir
      The output directory for generated resources files
    • resourceDir

      @Parameter(defaultValue="${project.basedir}/src/main/resources") protected File resourceDir
      The resources directory for configuration files
  • Constructor Details

    • GenerateMojo

      public GenerateMojo()
  • Method Details

    • 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
    • doExecuteRoutes

      protected void doExecuteRoutes(org.apache.camel.language.csimple.CSimpleCodeGenerator generator)
    • updateResource

      public static boolean updateResource(Path out, String data)