ehcache

net.sf.ehcache.config
Class DiskStoreConfiguration

java.lang.Object
  extended by net.sf.ehcache.config.DiskStoreConfiguration

public final class DiskStoreConfiguration
extends java.lang.Object

A class to represent DiskStore configuration e.g.

Version:
$Id: DiskStoreConfiguration.java 1619 2010-01-08 15:46:20Z cdennis $
Author:
Greg Luck

Constructor Summary
DiskStoreConfiguration()
           
 
Method Summary
static java.lang.String getDefaultPath()
          The diskStore default path, which is the system environment variable availablen on all Java virtual machines java.io.tmpdir
 java.lang.String getOriginalPath()
           
 java.lang.String getPath()
          The diskStore path
static java.lang.String replaceToken(java.lang.String token, java.lang.String replacement, java.lang.String source)
          Replaces a token with replacement text.
 void setPath(java.lang.String path)
          Translates and sets the path.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DiskStoreConfiguration

public DiskStoreConfiguration()
Method Detail

getPath

public final java.lang.String getPath()
The diskStore path


getDefaultPath

public static java.lang.String getDefaultPath()
The diskStore default path, which is the system environment variable availablen on all Java virtual machines java.io.tmpdir


setPath

public final void setPath(java.lang.String path)
Translates and sets the path.

Parameters:
path - If the path contains a Java System Property token it is replaced by its value in the running VM. Subdirectories can be specified below the property e.g. java.io.tmpdir/one. The following properties are translated:
  • user.home - User's home directory
  • user.dir - User's current working directory
  • java.io.tmpdir - Default temp file path
  • ehcache.disk.store.di?r - A system property you would normally specify on the command linecan specify with -DDefault temp file path e.g. java -Dehcache.disk.store.dir=/u01/myapp/diskdir ...
Additional strings can be placed before and after tokens? e.g. java.io/tmpdir/caches might become /tmp/caches

getOriginalPath

public java.lang.String getOriginalPath()
Returns:
the originalPath

replaceToken

public static java.lang.String replaceToken(java.lang.String token,
                                            java.lang.String replacement,
                                            java.lang.String source)
Replaces a token with replacement text.

Parameters:
token -
replacement -
source -
Returns:
the String with replacement text applied

ehcache

true