Class AbstractJLinkMojo

  • All Implemented Interfaces:
    org.apache.maven.plugin.ContextEnabled, org.apache.maven.plugin.Mojo
    Direct Known Subclasses:
    JLinkMojo

    public abstract class AbstractJLinkMojo
    extends org.apache.maven.plugin.AbstractMojo
    Author:
    Karl Heinz Marbaise khmarbaise@apache.org
    • Constructor Detail

      • AbstractJLinkMojo

        public AbstractJLinkMojo()
    • Method Detail

      • executeCommand

        protected void executeCommand​(org.codehaus.plexus.util.cli.Commandline cmd,
                                      File outputDirectory)
                               throws org.apache.maven.plugin.MojoExecutionException
        Throws:
        org.apache.maven.plugin.MojoExecutionException
      • getToolchain

        protected org.apache.maven.toolchain.Toolchain getToolchain()
      • getProject

        protected org.apache.maven.project.MavenProject getProject()
      • getSession

        protected org.apache.maven.execution.MavenSession getSession()
      • getArchiveFile

        protected File getArchiveFile​(File basedir,
                                      String finalName,
                                      String classifier,
                                      String archiveExt)
        Returns the archive file to generate, based on an optional classifier.
        Parameters:
        basedir - the output directory
        finalName - the name of the ear file
        classifier - an optional classifier
        archiveExt - The extension of the file.
        Returns:
        the file to generate
      • hasClassifier

        protected boolean hasClassifier​(String classifier)
      • convertSeparatedModulePathToPlatformSeparatedModulePath

        protected StringBuilder convertSeparatedModulePathToPlatformSeparatedModulePath​(String pluginModulePath)
        This will convert a module path separated by either : or ; into a string which uses the platform depend path separator uniformly.
        Parameters:
        pluginModulePath - The module path.
        Returns:
        The platform separated module path.
      • getPlatformDependSeparateList

        protected String getPlatformDependSeparateList​(List<String> modulePaths)
        Convert a list into a string which is separated by platform depend path separator.
        Parameters:
        modulePaths - The list of elements.
        Returns:
        The string which contains the elements separated by File.pathSeparatorChar.
      • getCommaSeparatedList

        protected String getCommaSeparatedList​(List<String> modules)
        Convert a list into a
        Parameters:
        modules - The list of modules.
        Returns:
        The string with the module list which is separated by ,.