|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.schmant.support.AbstractArgumentChecker
org.schmant.task.stub.AbstractTask<T>
org.schmant.task.template.process.AbstractExtProcessTask<ExtJarSignerTask>
org.schmant.task.jdk.jarsigner.ExtJarSignerTask
public final class ExtJarSignerTask
Task for signing JAR files using a Java installation's jarsigner
command.
See ExtJarSignerTF
| Field Summary |
|---|
| Fields inherited from interface org.schmant.task.confable.OverwriteConfigurable |
|---|
DEFAULT_OVERWRITE_STRATEGY |
| Method Summary | |
|---|---|
ExtJarSignerTask |
addSource(Object o)
Add one or several sources. |
ExtJarSignerTask |
addSources(Object o)
This method does the same as SourceConfigurable.addSource(Object) |
ExtJarSignerTask |
clearSources()
Clear the collection of sources. |
void |
copyProperties(ExtJarSignerTask spec)
Copy the properties to the target object. |
File |
get()
Returns the produced object, or null if nothing is produced
yet. |
protected String |
getDefaultLogHeader()
Get the default log header to log (to level INFO) before the task is run if the task user has not set a custom header. |
ProcessResult |
getProcessResult()
Get the result of the external program. |
Object |
getSource()
Get the first source set. |
List<Object> |
getSources()
Get the source list. |
Object |
getTarget()
Get the target. |
protected void |
runInternal(Report r)
Subclasses implement this. |
ExtJarSignerTask |
setOverwrite(boolean b)
Should things be overwritten? If this is set to true, it is
equivalent to setting the overwrite strategy to
DoOverwriteAndLogWarning. |
ExtJarSignerTask |
setOverwriteStrategy(OverwriteStrategy strat)
Set a strategy for how to react to existing entities in locations where the task wants to write. |
ExtJarSignerTask |
setRelativeToBase(RelativeLocation rel)
This property is set with the task's source's location relative to a base location if the task is run within a recursive task. |
ExtJarSignerTask |
setSource(Object o)
Set one or several sources, discarding previously set sources. |
ExtJarSignerTask |
setSources(Object o)
This method does the same as SourceConfigurable.setSource(Object) |
ExtJarSignerTask |
setTarget(Object o)
Set the target. |
String |
toString()
Default implementation for tasks. |
protected Collection<String> |
validate(Report r)
This method may be overridden by subclasses to validate their configuration (including their TaskFactory:s) before the task is
run. |
| Methods inherited from class org.schmant.task.template.process.AbstractExtProcessTask |
|---|
addArgumentsToCommandList, execAndWait, getArguments, getEnvironmentVariables, getStderrStrategy, getStdoutStrategy, getWorkingDirectory, isFailOnErrors, isInheritEnvironmentVariables |
| Methods inherited from class org.schmant.task.stub.AbstractTask |
|---|
cancel, createTask, getDefaultLogFooter, 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.TaskSpecification |
|---|
createTask |
| Methods inherited from interface org.schmant.task.confable.LoggingConfigurable |
|---|
setLogFooter, setLogHeader, setReportLevel, setTraceLogging |
| Methods inherited from interface org.schmant.task.Task |
|---|
cancel, getDependencyForTasksScheduledByThisTask, getFailureCause, isCancelled, isDone, isInterrupted, isRunning, isSuccessful |
| Methods inherited from interface org.schmant.run.TaskDependency |
|---|
getDependencyObservable, getSatisfiedStateLock, isSatisfied |
| Methods inherited from interface org.schmant.task.TaskRunnable |
|---|
run |
| Method Detail |
|---|
public File get()
Producernull if nothing is produced
yet.
This method should be implemented thread-safe.
get in interface Producer<File>public ExtJarSignerTask setSource(Object o)
SourceConfigurable
setSource in interface SourceConfigurable<ExtJarSignerTask>o - The source. If this is a Collection or an
array, it is flattened (see
FlatteningList), and all objects in
the collection or array are set.
thispublic ExtJarSignerTask setSources(Object o)
SourceConfigurableSourceConfigurable.setSource(Object)
setSources in interface SourceConfigurable<ExtJarSignerTask>o - The source or sources.
thispublic ExtJarSignerTask addSource(Object o)
SourceConfigurable
addSource in interface SourceConfigurable<ExtJarSignerTask>o - The source. If this is a Collection or an
array, it is flattened (see
FlatteningList), and all sources in the
collection or array are added.
thispublic ExtJarSignerTask addSources(Object o)
SourceConfigurableSourceConfigurable.addSource(Object)
addSources in interface SourceConfigurable<ExtJarSignerTask>o - The source or sources.
thispublic ExtJarSignerTask clearSources()
SourceConfigurable
clearSources in interface SourceConfigurable<ExtJarSignerTask>this.public Object getSource()
SourceConfigured
getSource in interface SourceConfigurednull if no source
is set.public List<Object> getSources()
SourceConfigured
getSources in interface SourceConfigurednull.public ExtJarSignerTask setTarget(Object o)
TargetConfigurable
setTarget in interface TargetConfigurable<ExtJarSignerTask>o - The target.
thispublic Object getTarget()
TargetConfigured
getTarget in interface TargetConfigurednull if it is not set.public ExtJarSignerTask setOverwrite(boolean b)
OverwriteConfigurabletrue, it is
equivalent to setting the overwrite strategy to
DoOverwriteAndLogWarning. If this is set to false, it is
equivalent to setting the overwrite strategy to
DontOverwriteAndLogWarning.
setOverwrite in interface OverwriteConfigurable<ExtJarSignerTask>b - Should things be overwritten?
thispublic ExtJarSignerTask setOverwriteStrategy(OverwriteStrategy strat)
OverwriteConfigurable
setOverwriteStrategy in interface OverwriteConfigurable<ExtJarSignerTask>strat - The overwrite strategy.
thispublic ExtJarSignerTask setRelativeToBase(RelativeLocation rel)
SourceConfigurable
If the SourceConfigurable (this object) is an action task factory
that is used in a recursive action task, the recursive action
task sets this property for each created task.
setRelativeToBase in interface SourceConfigurable<ExtJarSignerTask>rel - The source's location relative to the base location.
thispublic ProcessResult getProcessResult()
AbstractExtProcessTask
getProcessResult in interface ExtProcessTask<ExtJarSignerTask>getProcessResult in class AbstractExtProcessTask<ExtJarSignerTask>protected String getDefaultLogHeader()
AbstractTaskThis is called after validating the task.
Return null to disable logging.
getDefaultLogHeader in class AbstractTask<ExtJarSignerTask>protected Collection<String> validate(Report r)
AbstractTaskTaskFactory:s) before the task is
run.
Validation errors are collected as strings. If this method is overridden,
always call super.validate.
validate in class AbstractTask<ExtJarSignerTask>r - A report to log warning and debug messages to. Validation errors
should not be logged, though. They are logged later.
protected void runInternal(Report r)
throws InterruptedException
AbstractTaskAbstractTask.validate(Report):d before
this method is called, see AbstractTask.run().
runInternal in class AbstractTask<ExtJarSignerTask>r - The current thread's Report.
InterruptedExceptionpublic void copyProperties(ExtJarSignerTask spec)
AbstractTask
Subclasses must override this to copy their properties. The
overriding method must call super.copyProperties.
copyProperties in interface TaskSpecification<ExtJarSignerTask>copyProperties in class AbstractExtProcessTask<ExtJarSignerTask>spec - The specification to copy properties to.public String toString()
AbstractTaskThis implementation just returns the class name.
toString in class AbstractTask<ExtJarSignerTask>
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||