com.opensymphony.oscache.base.events
Class CachewideEvent

java.lang.Object
  extended bycom.opensymphony.oscache.base.events.CacheEvent
      extended bycom.opensymphony.oscache.base.events.CachewideEvent

public final class CachewideEvent
extends CacheEvent

A CachewideEvent represents and event that occurs on the the entire cache, eg a cache flush or clear.

Version:
$Revision: 1.1 $
Author:
Chris Miller

Field Summary
 
Fields inherited from class com.opensymphony.oscache.base.events.CacheEvent
origin
 
Constructor Summary
CachewideEvent(Cache cache, Date date, String origin)
          Constructs a cachewide event with the specified origin.
 
Method Summary
 Cache getCache()
          Retrieve the cache map that the event occurred on.
 Date getDate()
          Retrieve the date/time that the cache flush is scheduled for.
 
Methods inherited from class com.opensymphony.oscache.base.events.CacheEvent
getOrigin
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CachewideEvent

public CachewideEvent(Cache cache,
                      Date date,
                      String origin)
Constructs a cachewide event with the specified origin.

Parameters:
cache - The cache map that the event occurred on.
date - The date/time that this cachewide event is scheduled for (eg, the date that the cache is to be flushed).
origin - An optional tag that can be attached to the event to specify the event's origin. This is useful to prevent events from being fired recursively in some situations, such as when an event handler causes another event to be fired.
Method Detail

getCache

public Cache getCache()
Retrieve the cache map that the event occurred on.


getDate

public Date getDate()
Retrieve the date/time that the cache flush is scheduled for.


OSCache Project Page