Base class for tasks that cache arbitrary binaries.
Fields inherited from class | Fields |
---|---|
class DefaultTask |
TASK_NAME, TASK_DESCRIPTION, TASK_GROUP, TASK_TYPE, TASK_DEPENDS_ON, TASK_OVERWRITE, TASK_ACTION, TASK_CONSTRUCTOR_ARGS |
class AbstractTask |
TASK_NAME, TASK_DESCRIPTION, TASK_GROUP, TASK_TYPE, TASK_DEPENDS_ON, TASK_OVERWRITE, TASK_ACTION, TASK_CONSTRUCTOR_ARGS |
Type | Name and description |
---|---|
Provider<File> |
locationPropertiesFile |
Constructor and description |
---|
protected AbstractCacheBinaryTask
(String locationPropertiesDefaultName)
|
Type Params | Return Type | Name and description |
---|---|---|
|
void |
exec() |
|
protected java.util.Map<String, String> |
getAdditionalProperties() Returns additional properties to be added to the cached binary properties file. |
|
protected String |
getBinaryLocation() Obtains location of executable binary or script |
|
protected String |
getBinaryVersion() Obtains version of binary or script |
|
java.util.Map<String, String> |
getCachedBinaryProperties() |
|
Provider<File> |
getLocationPropertiesFile() |
|
protected String |
getPropertiesDescription() Obtains a description to be added to the cached binary properties file. |
|
void |
setLocationPropertiesFile(Object o) |
|
protected void |
writePropertiesShellFile(File destFile, java.util.Map<String, String> allprops) Write a shell file of properties. |
|
protected void |
writeWindowsPropertiesBatFile(File destFile, java.util.Map<String, String> allprops) Writes a Windows batch file of property values that can be included by a wrapper script. |
locationPropertiesDefaultName
- The default name for the location properties file.
Can include a relative pathReturns additional properties to be added to the cached binary properties file. The default implementation returns an empty map.
null
.Obtains location of executable binary or script
Obtains version of binary or script
null
.Obtains a description to be added to the cached binary properties file.
null
.Write a shell file of properties. The default implementation simply write a Java properties file as it is compatible enough with POSIX shell files.
destFile
- Destination file (assumes parent path exists)allprops
- Properties to write to dot-include file.Writes a Windows batch file of property values that can be included by a wrapper script. Property values that contain spaces will be wrapped in double quotes.
destFile
- Destination file (assumes parent path exists)allprops
- Properties to write to batch file.Groovy Documentation