Top Description Methods
net.sf.ehcache.management

public Interface CacheMBean

Known Direct Implementers
net.sf.ehcache.management.Cache
Imports
net.sf.ehcache.CacheException

A management bean for a cache
Author
Greg Luck
Since
1.3
Version
$Id: CacheMBean.java 5594 2012-05-07 16:04:31Z cdennis $

Method Summary

Modifier and TypeMethod and Description
public void
flush()

Flushes all cache items from memory to the disk store, and from the DiskStore to disk.

public CacheConfiguration
getCacheConfiguration()

Gets the JMX read-only CacheConfiguration

public String
getName()

Gets the cache name.

public CacheStatistics
getStatistics()

Gets the JMX cache statistics

public String

Returns:

The status value from the Status enum class
getStatus
()

Gets the status attribute of the Cache.

public boolean
hasAbortedSizeOf()

Check if the cache may contain elements which the SizeOf engine could not fully size.

public boolean
isTerracottaClustered()

Uses a Terracotta clustered store.

public void
removeAll()

Removes all cached items.

Method Detail

flushback to summary
public void flush() throws IllegalStateException, CacheException

Flushes all cache items from memory to the disk store, and from the DiskStore to disk.

Exceptions
IllegalStateException:
if the cache is not net.sf.ehcache.Status#STATUS_ALIVE
getCacheConfigurationback to summary
public CacheConfiguration getCacheConfiguration()

Gets the JMX read-only CacheConfiguration

getNameback to summary
public String getName()

Gets the cache name.

getStatisticsback to summary
public CacheStatistics getStatistics()

Gets the JMX cache statistics

getStatusback to summary
public String getStatus()

Gets the status attribute of the Cache.

Returns:String

The status value from the Status enum class

hasAbortedSizeOfback to summary
public boolean hasAbortedSizeOf()

Check if the cache may contain elements which the SizeOf engine could not fully size.

isTerracottaClusteredback to summary
public boolean isTerracottaClustered()

Uses a Terracotta clustered store.

removeAllback to summary
public void removeAll() throws IllegalStateException, CacheException

Removes all cached items.

Exceptions
IllegalStateException:
if the cache is not net.sf.ehcache.Status#STATUS_ALIVE