Class AbstractCompressingArbitraryFileCacheStrategy
- java.lang.Object
-
- jenkins.plugins.jobcacher.arbitrary.AbstractCompressingArbitraryFileCacheStrategy
-
- All Implemented Interfaces:
Serializable
,ArbitraryFileCacheStrategy
- Direct Known Subclasses:
TarArbitraryFileCacheStrategy
,ZipArbitraryFileCacheStrategy
public abstract class AbstractCompressingArbitraryFileCacheStrategy extends Object implements ArbitraryFileCacheStrategy
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description AbstractCompressingArbitraryFileCacheStrategy()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description void
cache(FilePath localSource, String includes, String excludes, boolean useDefaultExcludes, ObjectPath remoteTarget, FilePath workspace)
protected abstract void
compress(FilePath source, String includes, String excludes, boolean useDefaultExcludes, FilePath target)
String
createCacheName(String cacheBaseName)
protected abstract String
getArchiveExtension()
void
restore(ObjectPath remoteSource, FilePath localTarget, FilePath workspace)
protected abstract void
uncompress(FilePath source, FilePath target)
-
-
-
Method Detail
-
createCacheName
public String createCacheName(String cacheBaseName)
- Specified by:
createCacheName
in interfaceArbitraryFileCacheStrategy
-
cache
public void cache(FilePath localSource, String includes, String excludes, boolean useDefaultExcludes, ObjectPath remoteTarget, FilePath workspace) throws IOException, InterruptedException
- Specified by:
cache
in interfaceArbitraryFileCacheStrategy
- Throws:
IOException
InterruptedException
-
restore
public void restore(ObjectPath remoteSource, FilePath localTarget, FilePath workspace) throws IOException, InterruptedException
- Specified by:
restore
in interfaceArbitraryFileCacheStrategy
- Throws:
IOException
InterruptedException
-
getArchiveExtension
protected abstract String getArchiveExtension()
-
uncompress
protected abstract void uncompress(FilePath source, FilePath target) throws IOException, InterruptedException
- Throws:
IOException
InterruptedException
-
compress
protected abstract void compress(FilePath source, String includes, String excludes, boolean useDefaultExcludes, FilePath target) throws IOException, InterruptedException
- Throws:
IOException
InterruptedException
-
-