Class DirectoryBuildCache
java.lang.Object
org.gradle.caching.configuration.AbstractBuildCache
org.gradle.caching.local.DirectoryBuildCache
- All Implemented Interfaces:
BuildCache
Configuration object for the local directory build cache.
- Since:
- 3.5
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns the directory to use to store the build cache.intReturns the number of days after unused entries are garbage collected.voidsetDirectory(Object directory) Sets the directory to use to store the build cache.voidsetRemoveUnusedEntriesAfterDays(int removeUnusedEntriesAfterDays) Sets the number of days after unused entries are garbage collected.Methods inherited from class AbstractBuildCache
isEnabled, isPush, setEnabled, setPush
-
Constructor Details
-
DirectoryBuildCache
public DirectoryBuildCache()
-
-
Method Details
-
getDirectory
Returns the directory to use to store the build cache. -
setDirectory
Sets the directory to use to store the build cache. The directory is evaluated as perProject.file(Object). -
getRemoveUnusedEntriesAfterDays
public int getRemoveUnusedEntriesAfterDays()Returns the number of days after unused entries are garbage collected. Defaults to 7 days.- Since:
- 4.6
-
setRemoveUnusedEntriesAfterDays
public void setRemoveUnusedEntriesAfterDays(int removeUnusedEntriesAfterDays) Sets the number of days after unused entries are garbage collected. Defaults to 7 days. Must be greater than 1.- Since:
- 4.6
-