Package org.codehaus.mojo.gwt.shell
Class AbstractGwtShellMojo
- java.lang.Object
-
- org.apache.maven.plugin.AbstractMojo
-
- org.codehaus.mojo.gwt.AbstractGwtMojo
-
- org.codehaus.mojo.gwt.AbstractGwtModuleMojo
-
- org.codehaus.mojo.gwt.shell.AbstractGwtShellMojo
-
- All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled,org.apache.maven.plugin.Mojo,GwtModuleReader
- Direct Known Subclasses:
AbstractGwtWebMojo,CompileMojo,CSSMojo,I18NMojo,SuperDevModeMojo,TestMojo
public abstract class AbstractGwtShellMojo extends AbstractGwtModuleMojo
Support running GWT SDK Tools as forked JVM with classpath set according to project source/resource directories and dependencies.- Version:
- $Id$
- Author:
- ccollins, cooper, willpugh
-
-
Field Summary
Fields Modifier and Type Field Description protected StringstyleGWT JavaScript compiler output style (-style OBF[USCATED], PRETTY, or DETAILED).-
Fields inherited from class org.codehaus.mojo.gwt.AbstractGwtMojo
artifactFactory, artifactMetadataSource, classpathBuilder, GWT_DEV, GWT_GROUP_ID, GWT_USER, gwtSdkFirstInClasspath, localRepository, modulePathPrefix, remoteRepositories, resolver, session, warSourceDirectory
-
-
Constructor Summary
Constructors Constructor Description AbstractGwtShellMojo()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected voidaddArgumentDeploy(JavaCommand cmd)protected voidaddArgumentGen(JavaCommand cmd)protected voidaddCompileSourceArtifacts(JavaCommand cmd)Add sources.jar artifacts for project dependencies listed as compileSourcesArtifacts.protected voidaddPersistentUnitCache(JavaCommand cmd)protected JavaCommandcreateJavaCommand()abstract voiddoExecute()voidexecute()protected StringgetExtraJvmArgs()protected StringgetJvm()protected StringgetLogLevel()protected StringgetStyle()protected voidpostProcessClassPath(Collection<File> classpath)hook to post-process the dependency-based classpathvoidsetTimeOut(int timeOut)-
Methods inherited from class org.codehaus.mojo.gwt.AbstractGwtModuleMojo
getGwtModules, getModules, readModule
-
Methods inherited from class org.codehaus.mojo.gwt.AbstractGwtMojo
addClasspathElements, addCompileSourceRoot, getClasspath, getGenerateDirectory, getGwtDevJar, getGwtUserJar, getJarFiles, getLocalRepository, getOutputDirectory, getProject, getProjectArtifacts, getProjectRuntimeArtifacts, getRemoteRepositories, isGenerator, resolve, setupGenerateDirectory
-
-
-
-
Field Detail
-
style
@Parameter(property="gwt.style") protected String style
GWT JavaScript compiler output style (-style OBF[USCATED], PRETTY, or DETAILED).Can be set from command line using '-Dgwt.style=...'
-
-
Method Detail
-
execute
public final void execute() throws org.apache.maven.plugin.MojoExecutionException, org.apache.maven.plugin.MojoFailureException- Throws:
org.apache.maven.plugin.MojoExecutionExceptionorg.apache.maven.plugin.MojoFailureException- See Also:
Mojo.execute()
-
doExecute
public abstract void doExecute() throws org.apache.maven.plugin.MojoExecutionException, org.apache.maven.plugin.MojoFailureException- Throws:
org.apache.maven.plugin.MojoExecutionExceptionorg.apache.maven.plugin.MojoFailureException
-
getExtraJvmArgs
protected String getExtraJvmArgs()
-
getLogLevel
protected String getLogLevel()
-
getStyle
protected String getStyle()
-
getJvm
protected String getJvm()
-
postProcessClassPath
protected void postProcessClassPath(Collection<File> classpath)
hook to post-process the dependency-based classpath
-
setTimeOut
public void setTimeOut(int timeOut)
- Parameters:
timeOut- the timeOut to set
-
createJavaCommand
protected JavaCommand createJavaCommand()
-
addCompileSourceArtifacts
protected void addCompileSourceArtifacts(JavaCommand cmd) throws org.apache.maven.plugin.MojoExecutionException
Add sources.jar artifacts for project dependencies listed as compileSourcesArtifacts. This is a GWT hack to avoid packaging java source files into JAR when sharing code between server and client. Typically, some domain model classes or business rules may be packaged as a separate Maven module. With GWT packaging this requires to distribute such classes with code, that may not be desirable.The hack can also be used to include utility code from external librariries that may not have been designed for GWT.
- Throws:
org.apache.maven.plugin.MojoExecutionException
-
addArgumentDeploy
protected void addArgumentDeploy(JavaCommand cmd)
-
addArgumentGen
protected void addArgumentGen(JavaCommand cmd)
-
addPersistentUnitCache
protected void addPersistentUnitCache(JavaCommand cmd)
-
-