# Class Cache

java.lang.Object
org.apache.catalina.webresources.Cache

public class Cache extends Object

## Field Summary

Fields
Modifier and Type
Field
Description
`protected static final StringManager`
`sm`

## Constructor Summary

Constructors
Constructor
Description
`Cache(StandardRoot root)`

## Method Summary

Modifier and Type
Method
Description
`protected void`
`backgroundProcess()`
`void`
`clear()`
`WebResourceRoot.CacheStrategy`
`getCacheStrategy()`
`long`
`getHitCount()`
`long`
`getLookupCount()`
`long`
`getMaxSize()`
`int`
`getObjectMaxSize()`
`int`
`getObjectMaxSizeBytes()`
`protected WebResource`
`getResource(String path, boolean useClassLoaderResources)`
`protected WebResource[]`
`getResources(String path, boolean useClassLoaderResources)`
`long`
`getSize()`
`long`
`getTtl()`
`void`
`setCacheStrategy(WebResourceRoot.CacheStrategy cacheStrategy)`
`void`
`setMaxSize(long maxSize)`
`void`
`setObjectMaxSize(int objectMaxSize)`
`void`
`setTtl(long ttl)`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Field Details

### sm

protected static final StringManager sm

## Constructor Details

### Cache

public Cache(StandardRoot root)

## Method Details

### getResource

protected WebResource getResource(String path, boolean useClassLoaderResources)

### getResources

protected WebResource[] getResources(String path, boolean useClassLoaderResources)

### backgroundProcess

protected void backgroundProcess()

### getCacheStrategy

public WebResourceRoot.CacheStrategy getCacheStrategy()

### setCacheStrategy

public void setCacheStrategy(WebResourceRoot.CacheStrategy cacheStrategy)

### getTtl

public long getTtl()

### setTtl

public void setTtl(long ttl)

### getMaxSize

public long getMaxSize()

### setMaxSize

public void setMaxSize(long maxSize)

### getLookupCount

public long getLookupCount()

### getHitCount

public long getHitCount()

### setObjectMaxSize

public void setObjectMaxSize(int objectMaxSize)

### getObjectMaxSize

public int getObjectMaxSize()

### getObjectMaxSizeBytes

public int getObjectMaxSizeBytes()

### clear

public void clear()

### getSize

public long getSize()