Class JspcMojo

  • All Implemented Interfaces:
    org.apache.maven.plugin.ContextEnabled, org.apache.maven.plugin.Mojo, org.apache.sling.scripting.jsp.jasper.Options

    @Mojo(name="jspc",
          defaultPhase=COMPILE,
          requiresDependencyResolution=COMPILE)
    public class JspcMojo
    extends org.apache.maven.plugin.AbstractMojo
    implements org.apache.sling.scripting.jsp.jasper.Options
    The JspcMojo is implements the Sling Maven JspC goal jspc compiling JSP into the target and creating a component descriptor for Declarative Services to use the JSP with the help of the appropriate adapter as component.
    • Field Detail

      • mavenSession

        @Parameter(property="session",
                   defaultValue="${session}",
                   readonly=true,
                   required=true)
        protected org.apache.maven.execution.MavenSession mavenSession
      • projectHelper

        @Component
        protected org.apache.maven.project.MavenProjectHelper projectHelper
    • Constructor Detail

      • JspcMojo

        public JspcMojo()
    • Method Detail

      • execute

        public void execute()
                     throws org.apache.maven.plugin.MojoExecutionException
        Specified by:
        execute in interface org.apache.maven.plugin.Mojo
        Throws:
        org.apache.maven.plugin.MojoExecutionException
      • genStringAsCharArray

        public boolean genStringAsCharArray()
        Specified by:
        genStringAsCharArray in interface org.apache.sling.scripting.jsp.jasper.Options
      • getClassDebugInfo

        public boolean getClassDebugInfo()
        Specified by:
        getClassDebugInfo in interface org.apache.sling.scripting.jsp.jasper.Options
      • getCompiler

        public String getCompiler()
        Specified by:
        getCompiler in interface org.apache.sling.scripting.jsp.jasper.Options
      • getCompilerClassName

        public String getCompilerClassName()
        Specified by:
        getCompilerClassName in interface org.apache.sling.scripting.jsp.jasper.Options
      • getCompilerSourceVM

        public String getCompilerSourceVM()
        Specified by:
        getCompilerSourceVM in interface org.apache.sling.scripting.jsp.jasper.Options
      • getCompilerTargetVM

        public String getCompilerTargetVM()
        Specified by:
        getCompilerTargetVM in interface org.apache.sling.scripting.jsp.jasper.Options
      • getErrorOnUseBeanInvalidClassAttribute

        public boolean getErrorOnUseBeanInvalidClassAttribute()
        Specified by:
        getErrorOnUseBeanInvalidClassAttribute in interface org.apache.sling.scripting.jsp.jasper.Options
      • getFork

        public boolean getFork()
        Specified by:
        getFork in interface org.apache.sling.scripting.jsp.jasper.Options
      • getIeClassId

        public String getIeClassId()
        Specified by:
        getIeClassId in interface org.apache.sling.scripting.jsp.jasper.Options
      • getJavaEncoding

        public String getJavaEncoding()
        Specified by:
        getJavaEncoding in interface org.apache.sling.scripting.jsp.jasper.Options
      • getJspConfig

        public org.apache.sling.scripting.jsp.jasper.compiler.JspConfig getJspConfig()
        Specified by:
        getJspConfig in interface org.apache.sling.scripting.jsp.jasper.Options
      • getKeepGenerated

        public boolean getKeepGenerated()
        Specified by:
        getKeepGenerated in interface org.apache.sling.scripting.jsp.jasper.Options
      • getMappedFile

        public boolean getMappedFile()
        Specified by:
        getMappedFile in interface org.apache.sling.scripting.jsp.jasper.Options
      • getScratchDir

        public String getScratchDir()
        Specified by:
        getScratchDir in interface org.apache.sling.scripting.jsp.jasper.Options
      • getSendErrorToClient

        public boolean getSendErrorToClient()
        Specified by:
        getSendErrorToClient in interface org.apache.sling.scripting.jsp.jasper.Options
      • getTagPluginManager

        public org.apache.sling.scripting.jsp.jasper.compiler.TagPluginManager getTagPluginManager()
        Specified by:
        getTagPluginManager in interface org.apache.sling.scripting.jsp.jasper.Options
      • getTldLocationsCache

        public org.apache.sling.scripting.jsp.jasper.compiler.TldLocationsCache getTldLocationsCache()
        Specified by:
        getTldLocationsCache in interface org.apache.sling.scripting.jsp.jasper.Options
      • getTrimSpaces

        public boolean getTrimSpaces()
        Specified by:
        getTrimSpaces in interface org.apache.sling.scripting.jsp.jasper.Options
      • isPoolingEnabled

        public boolean isPoolingEnabled()
        Specified by:
        isPoolingEnabled in interface org.apache.sling.scripting.jsp.jasper.Options
      • isSmapDumped

        public boolean isSmapDumped()
        Specified by:
        isSmapDumped in interface org.apache.sling.scripting.jsp.jasper.Options
      • isSmapSuppressed

        public boolean isSmapSuppressed()
        Specified by:
        isSmapSuppressed in interface org.apache.sling.scripting.jsp.jasper.Options
      • isXpoweredBy

        public boolean isXpoweredBy()
        Specified by:
        isXpoweredBy in interface org.apache.sling.scripting.jsp.jasper.Options
      • getDisplaySourceFragment

        public boolean getDisplaySourceFragment()
        Specified by:
        getDisplaySourceFragment in interface org.apache.sling.scripting.jsp.jasper.Options
      • getOrResolveArtifact

        public static org.apache.maven.artifact.Artifact getOrResolveArtifact​(org.apache.maven.project.MavenProject project,
                                                                              org.apache.maven.execution.MavenSession session,
                                                                              org.apache.maven.artifact.handler.manager.ArtifactHandlerManager artifactHandlerManager,
                                                                              org.apache.maven.artifact.resolver.ArtifactResolver resolver,
                                                                              org.apache.sling.feature.ArtifactId id)