@@ -117,13 +117,13 @@ public class FileDownloaderCache {
117
117
}
118
118
}
119
119
120
- static Optional <FileCached > getFileCached (final URL remoteURL )
120
+ public static Optional <FileCached > getFileCached (final URL remoteURL )
121
121
throws URISyntaxException , NoSuchMethodException , ScriptException ,
122
122
IOException {
123
123
return getFileCached (remoteURL , true );
124
124
}
125
125
126
- static Optional <FileCached > getFileCached (final URL remoteURL , boolean enableCache )
126
+ public static Optional <FileCached > getFileCached (final URL remoteURL , boolean enableCache )
127
127
throws URISyntaxException , NoSuchMethodException , ScriptException ,
128
128
IOException {
129
129
// Return always and empty file if the cache is not enable
@@ -313,7 +313,7 @@ Optional<File> getFileFromCache() {
313
313
314
314
}
315
315
316
- synchronized void updateCacheFile (File fileToCache ) throws Exception {
316
+ public synchronized void updateCacheFile (File fileToCache ) throws Exception {
317
317
Path cacheFilePath = Paths .get (localPath );
318
318
319
319
// If the cache directory does not exist create it
@@ -343,7 +343,7 @@ synchronized void updateCacheFile(File fileToCache) throws Exception {
343
343
344
344
}
345
345
346
- synchronized void invalidateCache () throws IOException {
346
+ public synchronized void invalidateCache () throws IOException {
347
347
cachedFiles .remove (remoteURL );
348
348
Files .deleteIfExists (Paths .get (localPath ));
349
349
}
@@ -356,7 +356,7 @@ private String calculateMD5() throws IOException, NoSuchAlgorithmException {
356
356
}
357
357
358
358
@ JsonIgnore
359
- boolean md5Check () {
359
+ public boolean md5Check () {
360
360
try {
361
361
return !Objects .isNull (getMD5 ()) && Objects .equals (calculateMD5 (), getMD5 ());
362
362
} catch (Exception e ) {
@@ -366,7 +366,7 @@ boolean md5Check() {
366
366
}
367
367
368
368
@ JsonIgnore
369
- LocalDateTime getExpiresTime () {
369
+ public LocalDateTime getExpiresTime () {
370
370
final int maxAge ;
371
371
if (cacheControl != null ) {
372
372
maxAge = cacheControl .getMaxAge ();
0 commit comments