1 package de.nava.informa.utils; 25 26 import org.apache.commons.logging.Log; 27 import org.apache.commons.logging.LogFactory; 28 29 import de.nava.informa.core.ChannelIF; 30 31 34 public class RSS091Settings implements CacheSettingsIF { 35 36 private static Log logger = LogFactory.getLog(RSS100Settings.class); 37 38 private long defaultTtl = DEFAULT_TTL; 39 40 public void setDefaultTtl(long defaultTtl) { 41 this.defaultTtl = defaultTtl; 42 } 43 44 47 public long getTtl(ChannelIF channel, long Ttlms) { 48 logger.info("getTtl call RSS091 ask:" + Ttlms + " def:" + defaultTtl 49 + " feed :" + channel.toString()); 50 if (Ttlms > MINIMAL_TTL) { 51 52 return Ttlms; 53 } else { 54 return defaultTtl; 55 } 56 } 57 58 } | Popular Tags |