Class AddResourceMojo

  • All Implemented Interfaces:
    org.apache.maven.plugin.ContextEnabled, org.apache.maven.plugin.Mojo

    @Mojo(name="add-resource",
          defaultPhase=GENERATE_RESOURCES,
          threadSafe=true)
    public class AddResourceMojo
    extends AbstractAddResourceMojo
    Add more resource directories to the POM.
    Since:
    1.3
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private boolean skipAddResource
      Skip plugin execution.
      private boolean skipAddResourceIfMissing
      If a resource directory does not exist, do not add it as a root.
      • Fields inherited from interface org.apache.maven.plugin.Mojo

        ROLE
    • Constructor Summary

      Constructors 
      Constructor Description
      AddResourceMojo()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void addResource​(org.apache.maven.model.Resource resource)
      Add the resource to the project.
      protected boolean isSkip()  
      protected boolean isSkipIfMissing()  
      • 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 Detail

      • skipAddResource

        @Parameter(property="buildhelper.addresource.skip",
                   defaultValue="false")
        private boolean skipAddResource
        Skip plugin execution.
        Since:
        3.5.0
      • skipAddResourceIfMissing

        @Parameter(property="buildhelper.addresource.skipIfMissing",
                   defaultValue="false")
        private boolean skipAddResourceIfMissing
        If a resource directory does not exist, do not add it as a root.
        Since:
        3.5.0
    • Constructor Detail

      • AddResourceMojo

        public AddResourceMojo()