public class

DefaultOsgiPersistentCache

extends Object
implements OsgiPersistentCache
java.lang.Object
   ↳ com.atlassian.plugin.osgi.container.impl.DefaultOsgiPersistentCache

Class Overview

Default implementation of persistent cache. Handles clearing of directories if an upgrade has been detected.

Summary

Public Constructors
DefaultOsgiPersistentCache(File baseDir)
Constructs a cache, using the passed file as the base directory for cache subdirectories
DefaultOsgiPersistentCache(File baseDir, String applicationVersion)
This constructor is deprecated. No replacement.
Public Methods
void clear()
Clear all caches
File getFrameworkBundleCache()
File getOsgiBundleCache()
File getTransformedPluginCache()
void validate(String cacheValidationKey)
Validates the caches against a cache key.
[Expand]
Inherited Methods
From class java.lang.Object
From interface com.atlassian.plugin.osgi.container.OsgiPersistentCache

Public Constructors

public DefaultOsgiPersistentCache (File baseDir)

Constructs a cache, using the passed file as the base directory for cache subdirectories

Parameters
baseDir The base directory

public DefaultOsgiPersistentCache (File baseDir, String applicationVersion)

This constructor is deprecated.
No replacement.

Constructor added in the 2.2.0 beta timeframe, but was made redundant later. Application version is not used.

Public Methods

public void clear ()

Clear all caches

public File getFrameworkBundleCache ()

public File getOsgiBundleCache ()

public File getTransformedPluginCache ()

public void validate (String cacheValidationKey)

Validates the caches against a cache key. If the key changes, the directories are wiped clean.

Parameters
cacheValidationKey The cache key, can be anything