1 24 25 package org.objectweb.cjdbc.controller.cache.result; 26 27 import org.objectweb.cjdbc.common.sql.AbstractWriteRequest; 28 import org.objectweb.cjdbc.common.sql.ParsingGranularities; 29 import org.objectweb.cjdbc.common.sql.UpdateRequest; 30 import org.objectweb.cjdbc.controller.cache.result.entries.AbstractResultCacheEntry; 31 32 43 44 public class ResultCacheDatabase extends ResultCache 45 { 46 47 53 public ResultCacheDatabase(int maxEntries, int pendingTimeout) 54 { 55 super(maxEntries, pendingTimeout); 56 parsingGranularity = ParsingGranularities.NO_PARSING; 57 } 58 59 62 protected void processAddToCache(AbstractResultCacheEntry qe) 63 { 64 return; 65 } 66 67 70 public boolean isUpdateNecessary(UpdateRequest request) 71 { 72 return true; 73 } 74 75 78 protected void processWriteNotify(AbstractWriteRequest request) 79 { 80 flushCache(); 81 } 82 83 86 public String getName() 87 { 88 return "database"; 89 } 90 91 } | Popular Tags |