|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.schmant.support.AbstractArgumentChecker org.schmant.task.stub.AbstractTask<T> org.schmant.task.stub.AbstractActionTask<T> org.schmant.task.stub.AbstractProcessTask<T> org.schmant.task.template.jdk.javac.AbstractJavacTask<T>
public abstract class AbstractJavacTask<T extends AbstractJavacTask<T>>
Abstract base class for javac
task implementations.
Field Summary |
---|
Fields inherited from interface org.schmant.task.confable.OverwriteConfigurable |
---|
DEFAULT_OVERWRITE_STRATEGY |
Constructor Summary | |
---|---|
AbstractJavacTask()
|
Method Summary | |
---|---|
void |
copyProperties(T spec)
Override the implementation from AbstractTask to copy the
source properties. |
protected JavacAnnotationProcessingMode |
getAnnotationProcessingMode()
|
protected Map<String,String> |
getAnnotationProcessorOptions()
|
protected Object |
getAnnotationProcessorPath()
|
protected List<String> |
getAnnotationProcessors()
|
protected List<String> |
getArguments()
|
protected List<PathDecorator<?,?>> |
getClasspathDecorators()
|
protected List<Object> |
getClasspathEntries()
|
protected List<Object> |
getClasspathEntriesFromDecorators()
Get classpath entries from PathDecorator :s. |
protected Collection<JavacDebugKeyword> |
getDebugOptions()
|
protected String |
getEncoding()
|
protected JavacImplicitClassFileGeneration |
getImplicitClassFileGeneration()
|
protected List<String> |
getOptionsInternal()
Get the list of options that the compiler will get. |
protected String |
getSourceCodeVersion()
|
protected Object |
getSourceFilesDir()
|
protected String |
getTargetVersion()
|
protected abstract boolean |
hasSources()
This is implemented by subclasses to return true if any source
file property is set. |
protected boolean |
isDeprecation()
|
protected boolean |
isNowarn()
|
boolean |
isSourcesMandatory()
The sources are not mandatory for Javac tasks. |
protected void |
runInternal(Report r)
Subclasses implement this. |
protected abstract void |
runJavac(Report r)
This is implemented by subclasses. |
protected Collection<String> |
validate(Report r)
Override the method inherited from AbstractTask to give a validation
error if no source is set (and AbstractActionTask.isSourcesMandatory() is true ). |
Methods inherited from class org.schmant.task.stub.AbstractProcessTask |
---|
getOverwriteStrategy, getTarget, isTargetMandatory, setOverwrite, setOverwriteStrategy, setTarget, toString |
Methods inherited from class org.schmant.task.stub.AbstractActionTask |
---|
addSource, addSources, clearSources, getRelativeToBase, getSource, getSources, isMoreThanOneSourceAllowed, setRelativeToBase, setSource, setSources |
Methods inherited from class org.schmant.task.stub.AbstractTask |
---|
cancel, createTask, getDefaultLogFooter, getDefaultLogHeader, getDependencyForTasksScheduledByThisTask, getDependencyObservable, getFailureCause, getLogFooter, getLogHeader, getSatisfiedStateLock, getThis, isCancelled, isDone, isInterrupted, isRunning, isSatisfied, isSuccessful, run, setLogFooter, setLogHeader, setReportLevel, setTraceLogging |
Methods inherited from class org.schmant.support.AbstractArgumentChecker |
---|
check, check, check, check |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface org.schmant.task.confable.SourceConfigurable |
---|
addSource, addSources, clearSources, setRelativeToBase, setSource, setSources |
Methods inherited from interface org.schmant.task.confable.SourceConfigured |
---|
getSource, getSources |
Methods inherited from interface org.schmant.task.TaskSpecification |
---|
createTask |
Methods inherited from interface org.schmant.task.confable.LoggingConfigurable |
---|
setLogFooter, setLogHeader, setReportLevel, setTraceLogging |
Constructor Detail |
---|
public AbstractJavacTask()
Method Detail |
---|
protected final String getTargetVersion()
protected final String getSourceCodeVersion()
protected final List<Object> getClasspathEntries()
protected final List<PathDecorator<?,?>> getClasspathDecorators()
protected final List<String> getArguments()
protected final String getEncoding()
protected final Map<String,String> getAnnotationProcessorOptions()
protected final boolean isDeprecation()
protected final Collection<JavacDebugKeyword> getDebugOptions()
protected final JavacImplicitClassFileGeneration getImplicitClassFileGeneration()
protected final boolean isNowarn()
protected final JavacAnnotationProcessingMode getAnnotationProcessingMode()
protected final List<String> getAnnotationProcessors()
protected final Object getAnnotationProcessorPath()
protected final Object getSourceFilesDir()
public boolean isSourcesMandatory()
isSourcesMandatory
in class AbstractActionTask<T extends AbstractJavacTask<T>>
true
, always.protected List<String> getOptionsInternal()
protected List<Object> getClasspathEntriesFromDecorators()
PathDecorator
:s.
protected Collection<String> validate(Report r)
AbstractActionTask
AbstractTask
to give a validation
error if no source is set (and AbstractActionTask.isSourcesMandatory()
is true
).
Subclasses may override this to add their own validations.
validate
in class AbstractProcessTask<T extends AbstractJavacTask<T>>
r
- A report to log warning and debug messages to. Validation errors
should not be logged, though. They are logged later.
protected abstract boolean hasSources()
true
if any source
file property is set.
protected abstract void runJavac(Report r) throws InterruptedException
InterruptedException
protected final void runInternal(Report r) throws InterruptedException
AbstractTask
AbstractTask.validate(Report)
:d before
this method is called, see AbstractTask.run()
.
runInternal
in class AbstractTask<T extends AbstractJavacTask<T>>
r
- The current thread's Report
.
InterruptedException
public void copyProperties(T spec)
AbstractActionTask
AbstractTask
to copy the
source properties. Subclasses must override this to copy their own
properties.
copyProperties
in interface TaskSpecification<T extends AbstractJavacTask<T>>
copyProperties
in class AbstractProcessTask<T extends AbstractJavacTask<T>>
spec
- The specification to copy properties to.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |