/** * Store given item in the cache with a reference to supplied Tridion Item. * * @param key String representing the key to store the cacheItem under * @param cacheElement Object the actual value to store in cache * @param dependingPublicationId int representing the Publication id of the Tridion item the * cacheItem depends on * @param dependingItemId int representing the Item id of the Tridion item the cacheItem * depends on */ @Override public <T> void storeInItemCache(String key, CacheElement<T> cacheElement, int dependingPublicationId, int dependingItemId) { if (!isEnabled()) { return; } CacheDependency dependency = new CacheDependencyImpl(dependingPublicationId, dependingItemId); List<CacheDependency> dependencies = new ArrayList<>(); dependencies.add(dependency); storeInItemCache(key, cacheElement, dependencies); }