Package org.docstr.gradle.plugins.gwt
Class AbstractGwtCompile
- java.lang.Object
-
- org.gradle.api.internal.AbstractTask
-
- org.gradle.api.DefaultTask
-
- org.docstr.gradle.plugins.gwt.AbstractGwtActionTask
-
- org.docstr.gradle.plugins.gwt.AbstractGwtTask
-
- org.docstr.gradle.plugins.gwt.AbstractGwtCompile
-
- All Implemented Interfaces:
java.lang.Comparable<org.gradle.api.Task>
,GwtCompileOptions
,org.gradle.api.internal.DynamicObjectAware
,org.gradle.api.internal.TaskInternal
,org.gradle.api.plugins.ExtensionAware
,org.gradle.api.Task
,org.gradle.util.Configurable<org.gradle.api.Task>
- Direct Known Subclasses:
GwtCheck
,GwtCompile
,GwtDraftCompile
public class AbstractGwtCompile extends AbstractGwtTask implements GwtCompileOptions
Common implementation of tasks used for GWT compilation.
-
-
Constructor Summary
Constructors Constructor Description AbstractGwtCompile()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
addArgs()
Called directly before executing this task.protected void
configure(GwtCompileOptions options)
java.lang.Boolean
getClosureFormattedOutput()
java.lang.Boolean
getCompileReport()
java.lang.Boolean
getCompilerMetrics()
java.lang.Boolean
getDisableAggressiveOptimization()
java.lang.Boolean
getDisableCastChecking()
java.lang.Boolean
getDisableClassMetadata()
java.lang.Boolean
getDisableGeneratingOnShards()
java.lang.Boolean
getDisableRunAsync()
java.lang.Boolean
getDisableSoycHtml()
java.lang.Boolean
getDraftCompile()
java.lang.Boolean
getEa()
java.lang.Boolean
getEnforceStrictResources()
java.lang.Integer
getFragmentCount()
java.lang.Boolean
getIncrementalCompileWarnings()
java.lang.Integer
getLocalWorkers()
java.io.File
getMissingDepsFile()
Namespace
getNamespace()
java.lang.Integer
getOptimize()
java.lang.Boolean
getOverlappingSourceWarnings()
java.lang.Boolean
getSaveSource()
java.io.File
getSaveSourceOutput()
java.util.List<java.lang.String>
getSetProperties()
java.lang.Boolean
getSoycDetailed()
java.lang.Boolean
getStrict()
Style
getStyle()
java.lang.Boolean
getValidateOnly()
void
setClosureFormattedOutput(java.lang.Boolean closureFormattedOutput)
If set to true, this adds the parameter -XclosureFormattedOutput.void
setCompileReport(java.lang.Boolean compileReport)
If set to true, this adds the "-compileReport" flag.void
setCompilerMetrics(java.lang.Boolean compilerMetrics)
If set to true, this adds the "-XcompilerMetrics" flag.void
setDisableAggressiveOptimization(java.lang.Boolean disableAggressiveOptimization)
If set to true, this adds the "-XdisableAggressiveOptimization" flag.void
setDisableCastChecking(java.lang.Boolean disableCastChecking)
If set to true, this adds the "-XdisableCastChecking" flag.void
setDisableClassMetadata(java.lang.Boolean disableClassMetadata)
If set to true, this adds the "-XdisableClassMetadata" flag.void
setDisableGeneratingOnShards(java.lang.Boolean disableGeneratingOnShards)
If set to true, this adds the "-XdisableGeneratingOnShards" flag.void
setDisableRunAsync(java.lang.Boolean disableRunAsync)
If set to true, this adds the "-XdisableRunAsync" flag.void
setDisableSoycHtml(java.lang.Boolean disableSoycHtml)
If set to true, this adds the "-XdisableSoycHtml" flag.void
setDraftCompile(java.lang.Boolean draftCompile)
If set to true, this adds the "-draftCompile" flag.void
setEa(java.lang.Boolean ea)
If set to true, this adds the "-ea" (enable assertions) flag.void
setEnforceStrictResources(java.lang.Boolean enforceStrictResources)
void
setFragmentCount(java.lang.Integer fragmentCount)
Sets the "-XfragmentCount" option.void
setIncrementalCompileWarnings(java.lang.Boolean incrementalCompileWarnings)
void
setLocalWorkers(java.lang.Integer localWorkers)
Sets the "-localWorkers" option.void
setMissingDepsFile(java.io.File missingDepsFile)
void
setNamespace(Namespace namespace)
void
setOptimize(java.lang.Integer optimize)
Sets the "-optimize" option.void
setOverlappingSourceWarnings(java.lang.Boolean overlappingSourceWarnings)
void
setSaveSource(java.lang.Boolean saveSource)
void
setSaveSourceOutput(java.io.File saveSourceOutput)
void
setSetProperties(java.util.List<java.lang.String> properties)
Set the values of a property in the form of propertyName=value1[,value2...].void
setSoycDetailed(java.lang.Boolean soycDetailed)
If set to true, this adds the "-XsoycDetailed" flag.void
setStrict(java.lang.Boolean strict)
If set to true, this adds the "-strict" flag.void
setStyle(Style style)
Sets the "-style" option.void
setValidateOnly(java.lang.Boolean validateOnly)
If set to true, this adds the "-validateOnly" flag.-
Methods inherited from class org.docstr.gradle.plugins.gwt.AbstractGwtTask
getCacheDir, getDeploy, getExtra, getGen, getWar, getWorkDir, setCacheDir, setDeploy, setExtra, setGen, setWar, setWorkDir
-
Methods inherited from class org.docstr.gradle.plugins.gwt.AbstractGwtActionTask
argIfEnabled, argIfSet, argOnOff, args, dirArgIfSet, exec, getClasspath, getExtraJvmArgs, getGwtVersion, getIncremental, getJsInteropExports, getJsInteropMode, getLogLevel, getMaxHeapSize, getMethodNameDisplayMode, getMinHeapSize, getModules, getSourceLevel, getSrc, isDebug, isDevTask, isUseToolchain, jvmArgs, prependSrcToClasspath, setClasspath, setDebug, setExtraJvmArgs, setGwtVersion, setIncremental, setJsInteropExports, setJsInteropMode, setLogLevel, setMaxHeapSize, setMethodNameDisplayMode, setMinHeapSize, setModules, setSourceLevel, setSrc, setUseToolchain
-
Methods inherited from class org.gradle.api.DefaultTask
compareTo, configure, dependsOn, doFirst, doFirst, doFirst, doLast, doLast, doLast, finalizedBy, getActions, getAnt, getDependsOn, getDescription, getDestroyables, getDidWork, getEnabled, getExtensions, getFinalizedBy, getGroup, getInputs, getLocalState, getLogger, getLogging, getMustRunAfter, getName, getOutputs, getPath, getProject, getShouldRunAfter, getState, getTaskDependencies, getTemporaryDir, getTimeout, hasProperty, mustRunAfter, onlyIf, onlyIf, property, setActions, setDependsOn, setDescription, setDidWork, setEnabled, setFinalizedBy, setGroup, setMustRunAfter, setOnlyIf, setOnlyIf, setProperty, setShouldRunAfter, shouldRunAfter, usesService
-
Methods inherited from class org.gradle.api.internal.AbstractTask
appendParallelSafeAction, getAsDynamicObject, getConvention, getIdentityPath, getImpliesSubProjects, getOnlyIf, getRequiredServices, getServices, getSharedResources, getStandardOutputCapture, getTaskActions, getTaskIdentity, getTemporaryDirFactory, hasTaskActions, injectIntoNewInstance, isEnabled, isHasCustomActions, prependParallelSafeAction, setImpliesSubProjects
-
-
-
-
Method Detail
-
addArgs
protected void addArgs()
Description copied from class:AbstractGwtActionTask
Called directly before executing this task. Subclasses are expected to add all args/javaArgs needed for the execution.- Overrides:
addArgs
in classAbstractGwtTask
-
configure
protected void configure(GwtCompileOptions options)
-
getLocalWorkers
@Input public java.lang.Integer getLocalWorkers()
- Specified by:
getLocalWorkers
in interfaceGwtCompileOptions
-
setLocalWorkers
public void setLocalWorkers(java.lang.Integer localWorkers)
Sets the "-localWorkers" option.- Specified by:
setLocalWorkers
in interfaceGwtCompileOptions
- Parameters:
localWorkers
- Whether to add the "-localWorkers" option.
-
getDraftCompile
@Input @Optional public java.lang.Boolean getDraftCompile()
- Specified by:
getDraftCompile
in interfaceGwtCompileOptions
-
setDraftCompile
public void setDraftCompile(java.lang.Boolean draftCompile)
If set to true, this adds the "-draftCompile" flag.- Specified by:
setDraftCompile
in interfaceGwtCompileOptions
- Parameters:
draftCompile
- Whether to add the "-draftCompile" flag.
-
getCompileReport
@Input @Optional public java.lang.Boolean getCompileReport()
- Specified by:
getCompileReport
in interfaceGwtCompileOptions
-
setCompileReport
public void setCompileReport(java.lang.Boolean compileReport)
If set to true, this adds the "-compileReport" flag.- Specified by:
setCompileReport
in interfaceGwtCompileOptions
- Parameters:
compileReport
- Whether to add the "-compileReport" flag.
-
getCompilerMetrics
@Input @Optional public java.lang.Boolean getCompilerMetrics()
- Specified by:
getCompilerMetrics
in interfaceGwtCompileOptions
-
setCompilerMetrics
public void setCompilerMetrics(java.lang.Boolean compilerMetrics)
If set to true, this adds the "-XcompilerMetrics" flag.- Specified by:
setCompilerMetrics
in interfaceGwtCompileOptions
- Parameters:
compilerMetrics
- Whether to add the "-XcompilerMetrics" flag.
-
getValidateOnly
@Input @Optional public java.lang.Boolean getValidateOnly()
- Specified by:
getValidateOnly
in interfaceGwtCompileOptions
-
setValidateOnly
public void setValidateOnly(java.lang.Boolean validateOnly)
If set to true, this adds the "-validateOnly" flag.- Specified by:
setValidateOnly
in interfaceGwtCompileOptions
- Parameters:
validateOnly
- Whether to add the "-validateOnly" flag.
-
getDisableGeneratingOnShards
@Input @Optional public java.lang.Boolean getDisableGeneratingOnShards()
- Specified by:
getDisableGeneratingOnShards
in interfaceGwtCompileOptions
-
setDisableGeneratingOnShards
public void setDisableGeneratingOnShards(java.lang.Boolean disableGeneratingOnShards)
If set to true, this adds the "-XdisableGeneratingOnShards" flag.- Specified by:
setDisableGeneratingOnShards
in interfaceGwtCompileOptions
- Parameters:
disableGeneratingOnShards
- Whether to add the "-XdisableGeneratingOnShards" flag.
-
getOptimize
@Input @Optional public java.lang.Integer getOptimize()
- Specified by:
getOptimize
in interfaceGwtCompileOptions
-
setOptimize
public void setOptimize(java.lang.Integer optimize)
Sets the "-optimize" option.- Specified by:
setOptimize
in interfaceGwtCompileOptions
- Parameters:
optimize
- the optimization level to set. Valid values are in the interval [0, 9].
-
getDisableAggressiveOptimization
@Input @Optional public java.lang.Boolean getDisableAggressiveOptimization()
- Specified by:
getDisableAggressiveOptimization
in interfaceGwtCompileOptions
-
setDisableAggressiveOptimization
public void setDisableAggressiveOptimization(java.lang.Boolean disableAggressiveOptimization)
If set to true, this adds the "-XdisableAggressiveOptimization" flag.- Specified by:
setDisableAggressiveOptimization
in interfaceGwtCompileOptions
- Parameters:
disableAggressiveOptimization
- Whether to add the "-XdisableAggressiveOptimization" flag.
-
getDisableClassMetadata
@Input @Optional public java.lang.Boolean getDisableClassMetadata()
- Specified by:
getDisableClassMetadata
in interfaceGwtCompileOptions
-
setDisableClassMetadata
public void setDisableClassMetadata(java.lang.Boolean disableClassMetadata)
If set to true, this adds the "-XdisableClassMetadata" flag.- Specified by:
setDisableClassMetadata
in interfaceGwtCompileOptions
- Parameters:
disableClassMetadata
- Whether to add the "-XdisableClassMetadata" flag.
-
getDisableCastChecking
@Input @Optional public java.lang.Boolean getDisableCastChecking()
- Specified by:
getDisableCastChecking
in interfaceGwtCompileOptions
-
setDisableCastChecking
public void setDisableCastChecking(java.lang.Boolean disableCastChecking)
If set to true, this adds the "-XdisableCastChecking" flag.- Specified by:
setDisableCastChecking
in interfaceGwtCompileOptions
- Parameters:
disableCastChecking
- Whether to add the "-XdisableCastChecking" flag.
-
getEa
@Input @Optional public java.lang.Boolean getEa()
- Specified by:
getEa
in interfaceGwtCompileOptions
-
setEa
public void setEa(java.lang.Boolean ea)
If set to true, this adds the "-ea" (enable assertions) flag.- Specified by:
setEa
in interfaceGwtCompileOptions
- Parameters:
ea
- Whether to add the "-ea" (enable assertions) flag.
-
getDisableRunAsync
@Input @Optional public java.lang.Boolean getDisableRunAsync()
- Specified by:
getDisableRunAsync
in interfaceGwtCompileOptions
-
setDisableRunAsync
public void setDisableRunAsync(java.lang.Boolean disableRunAsync)
If set to true, this adds the "-XdisableRunAsync" flag.- Specified by:
setDisableRunAsync
in interfaceGwtCompileOptions
- Parameters:
disableRunAsync
- Whether to add the "-XdisableRunAsync" flag.
-
getStyle
@Input @Optional public Style getStyle()
- Specified by:
getStyle
in interfaceGwtCompileOptions
-
setStyle
public void setStyle(Style style)
Sets the "-style" option.- Specified by:
setStyle
in interfaceGwtCompileOptions
- Parameters:
style
- Whether to add the "-style" option.
-
getSoycDetailed
@Input @Optional public java.lang.Boolean getSoycDetailed()
- Specified by:
getSoycDetailed
in interfaceGwtCompileOptions
-
setSoycDetailed
public void setSoycDetailed(java.lang.Boolean soycDetailed)
If set to true, this adds the "-XsoycDetailed" flag.- Specified by:
setSoycDetailed
in interfaceGwtCompileOptions
- Parameters:
soycDetailed
- Whether to addthe "-XsoycDetailed" flag.
-
getStrict
@Input @Optional public java.lang.Boolean getStrict()
- Specified by:
getStrict
in interfaceGwtCompileOptions
-
setStrict
public void setStrict(java.lang.Boolean strict)
If set to true, this adds the "-strict" flag.- Specified by:
setStrict
in interfaceGwtCompileOptions
- Parameters:
strict
- Whether to add the "-strict" flag.
-
getDisableSoycHtml
@Input @Optional public java.lang.Boolean getDisableSoycHtml()
- Specified by:
getDisableSoycHtml
in interfaceGwtCompileOptions
-
setDisableSoycHtml
public void setDisableSoycHtml(java.lang.Boolean disableSoycHtml)
If set to true, this adds the "-XdisableSoycHtml" flag.- Specified by:
setDisableSoycHtml
in interfaceGwtCompileOptions
- Parameters:
disableSoycHtml
- Whether to add the "-XdisableSoycHtml" flag.
-
getFragmentCount
@Input @Optional public java.lang.Integer getFragmentCount()
- Specified by:
getFragmentCount
in interfaceGwtCompileOptions
-
setFragmentCount
public void setFragmentCount(java.lang.Integer fragmentCount)
Sets the "-XfragmentCount" option.- Specified by:
setFragmentCount
in interfaceGwtCompileOptions
- Parameters:
fragmentCount
- The "-XfragmentCount" option specified.
-
getMissingDepsFile
@Optional @InputFile @PathSensitive(ABSOLUTE) public java.io.File getMissingDepsFile()
- Specified by:
getMissingDepsFile
in interfaceGwtCompileOptions
-
setMissingDepsFile
public void setMissingDepsFile(java.io.File missingDepsFile)
- Specified by:
setMissingDepsFile
in interfaceGwtCompileOptions
- Parameters:
missingDepsFile
- the missingDepsFile to set
-
getNamespace
@Optional @Input public Namespace getNamespace()
- Specified by:
getNamespace
in interfaceGwtCompileOptions
-
setNamespace
public void setNamespace(Namespace namespace)
- Specified by:
setNamespace
in interfaceGwtCompileOptions
- Parameters:
namespace
- the namespace to set
-
getEnforceStrictResources
@Optional @Input public java.lang.Boolean getEnforceStrictResources()
- Specified by:
getEnforceStrictResources
in interfaceGwtCompileOptions
-
setEnforceStrictResources
public void setEnforceStrictResources(java.lang.Boolean enforceStrictResources)
- Specified by:
setEnforceStrictResources
in interfaceGwtCompileOptions
- Parameters:
enforceStrictResources
- the enforceStrictResources to set
-
getIncrementalCompileWarnings
@Optional @Input public java.lang.Boolean getIncrementalCompileWarnings()
- Specified by:
getIncrementalCompileWarnings
in interfaceGwtCompileOptions
-
setIncrementalCompileWarnings
public void setIncrementalCompileWarnings(java.lang.Boolean incrementalCompileWarnings)
- Specified by:
setIncrementalCompileWarnings
in interfaceGwtCompileOptions
- Parameters:
incrementalCompileWarnings
- the incrementalCompileWarnings to set
-
getOverlappingSourceWarnings
@Optional @Input public java.lang.Boolean getOverlappingSourceWarnings()
- Specified by:
getOverlappingSourceWarnings
in interfaceGwtCompileOptions
-
setOverlappingSourceWarnings
public void setOverlappingSourceWarnings(java.lang.Boolean overlappingSourceWarnings)
- Specified by:
setOverlappingSourceWarnings
in interfaceGwtCompileOptions
- Parameters:
overlappingSourceWarnings
- the overlappingSourceWarnings to set
-
getSaveSource
@Optional @Input public java.lang.Boolean getSaveSource()
- Specified by:
getSaveSource
in interfaceGwtCompileOptions
-
setSaveSource
public void setSaveSource(java.lang.Boolean saveSource)
- Specified by:
setSaveSource
in interfaceGwtCompileOptions
- Parameters:
saveSource
- the saveSource to set
-
getSaveSourceOutput
@Optional @OutputDirectory public java.io.File getSaveSourceOutput()
- Specified by:
getSaveSourceOutput
in interfaceGwtCompileOptions
-
setSaveSourceOutput
public void setSaveSourceOutput(java.io.File saveSourceOutput)
- Specified by:
setSaveSourceOutput
in interfaceGwtCompileOptions
- Parameters:
saveSourceOutput
- the saveSourceOutput to set
-
getClosureFormattedOutput
@Optional @Input public java.lang.Boolean getClosureFormattedOutput()
- Specified by:
getClosureFormattedOutput
in interfaceGwtCompileOptions
-
setClosureFormattedOutput
public void setClosureFormattedOutput(java.lang.Boolean closureFormattedOutput)
If set to true, this adds the parameter -XclosureFormattedOutput. If set to false, this adds the parameter -XnoclosureFormattedOutput. Added in GWT 2.8.- Specified by:
setClosureFormattedOutput
in interfaceGwtCompileOptions
- Parameters:
closureFormattedOutput
- The closure formatted output.
-
setSetProperties
public void setSetProperties(java.util.List<java.lang.String> properties)
Set the values of a property in the form of propertyName=value1[,value2...]. Example: -setProperties = ["user.agent=safari", "locale=default"] would add the parameters -setProperty user.agent=safari -setProperty locale=default- Specified by:
setSetProperties
in interfaceGwtCompileOptions
- Parameters:
properties
- The list of properties to be set
-
getSetProperties
@Optional @Input public java.util.List<java.lang.String> getSetProperties()
- Specified by:
getSetProperties
in interfaceGwtCompileOptions
-
-