protected void removeFromCache(RequestContext context, String id, JetspeedContentCache cache) { if (cache == null) return; ContentCacheKey cacheKey = cache.createCacheKey(context, id); if (cache.isKeyInCache(cacheKey)) { cache.remove(cacheKey); } cache.invalidate(context); }
protected void clearTargetCache(String fragmentId, RequestContext context) { ContentCacheKey cacheKey = portletContentCache.createCacheKey(context, fragmentId); if (portletContentCache.isKeyInCache(cacheKey)) { portletContentCache.remove(cacheKey); portletContentCache.invalidate(context); } }
private static void removeFromCache(RequestContext context, String id, JetspeedContentCache cache) { if (cache != null) { ContentCacheKey cacheKey = cache.createCacheKey(context, id); if (cache.isKeyInCache(cacheKey)) { cache.remove(cacheKey); } cache.invalidate(context); } }
protected void notifyFragments(ContentFragment f, RequestContext context, ContentPage page) { if (f.getFragments() != null && f.getFragments().size() > 0) { for (Object child : f.getFragments()) { if (!"hidden".equals(f.getState())) { notifyFragments((ContentFragment)child, context, page); } } } ContentCacheKey cacheKey = portletContentCache.createCacheKey(context, f.getId()); if (portletContentCache.isKeyInCache(cacheKey)) { portletContentCache.remove(cacheKey); portletContentCache.invalidate(context); } }
themeContentCacheKey = cache.createCacheKey(requestContext, page.getId()); CacheElement themeCacheElem = cache.get(themeContentCacheKey); themeContentCacheKey = cache.createCacheKey(requestContext, page.getId()); cache.remove(themeContentCacheKey); themeContentCacheKey = cache.createCacheKey(requestContext, page.getId()); requestContext.setSessionAttribute(themeCacheKey, theme);