01: /*
02: * Copyright (c) 2002-2003 by OpenSymphony
03: * All rights reserved.
04: */
05: package com.opensymphony.oscache.base;
06:
07: /**
08: * This is an dummy implementation of an EntryRefreshPolicy. It is just to
09: * illustrate how to use it.
10: *
11: * $Id: DummyAlwayRefreshEntryPolicy.java 254 2005-06-17 05:07:38Z dres $
12: * @version $Revision: 254 $
13: * @author <a href="mailto:fbeauregard@pyxis-tech.com">Francois Beauregard</a>
14: */
15: public final class DummyAlwayRefreshEntryPolicy implements
16: EntryRefreshPolicy {
17: /**
18: * Dummy implementation of an entry refresh policy. A real implementation
19: * whould do some logic to determine if this entry needs to be refreshed.
20: * It can be calling a bean or checking some files, or even manually manage
21: * the time expiration.
22: *
23: * <p>
24: * @param entry The entry for wich to determine if a refresh is needed
25: * @return True or false
26: */
27: public boolean needsRefresh(CacheEntry entry) {
28: return true;
29: }
30: }
|