1 48 49 50 package com.caucho.portal.generic; 51 52 import javax.portlet.RenderRequest; 53 import javax.portlet.RenderResponse; 54 import java.io.IOException ; 55 import java.io.OutputStream ; 56 import java.io.Writer ; 57 import java.util.Map ; 58 import java.util.logging.Logger ; 59 60 61 abstract public class Cache 62 { 63 protected static final Logger log = 64 Logger.getLogger(Cache.class.getName()); 65 66 98 abstract public int respondFromCache(CacheKey cacheKey, 99 RenderRequest request, 100 RenderResponse response); 101 102 126 abstract public Writer getCachingWriter(String namespace, 127 int expirationCache, 128 boolean isPrivate) 129 throws IOException ; 130 131 156 abstract public OutputStream getCachingOutputStream(String namespace, 157 int expirationCache, 158 boolean isPrivate) 159 160 throws IOException ; 161 162 197 abstract public void finishCaching( 198 Writer writer, 199 int expirationCache, 200 CacheKey cacheKey, 201 String encoding, 202 Map <String , Object > cachePropertiesMap, 203 Map <String , Object > propertiesMap, 204 Map <String , String > requestAttributeMap ); 205 206 211 abstract public void finishCaching( 212 OutputStream outputStream, 213 int expirationCache, 214 CacheKey cacheKey, 215 Map <String , Object > cachePropertiesMap, 216 Map <String , Object > propertiesMap, 217 Map <String , String > requestAttributeMap ); 218 } 219 220 | Popular Tags |