/** * @see org.opencms.loader.I_CmsResourceLoader#load(org.opencms.file.CmsObject, org.opencms.file.CmsResource, javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse) */ @Override public void load(CmsObject cms, CmsResource resource, HttpServletRequest req, HttpServletResponse res) throws IOException, CmsException { if (m_enabled) { if (canSendLastModifiedHeader(resource, req, res)) { // no image processing required at all return; } // get the scale information from the request CmsImageScaler scaler = new CmsImageScaler(req, m_maxScaleSize, m_maxBlurSize); // load the file from the cache CmsFile file = getScaledImage(cms, resource, scaler); // now perform standard load operation inherited from dump loader super.load(cms, file, req, res); } else { // scaling is disabled super.load(cms, resource, req, res); } }
/** * @see org.opencms.loader.I_CmsResourceLoader#load(org.opencms.file.CmsObject, org.opencms.file.CmsResource, javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse) */ @Override public void load(CmsObject cms, CmsResource resource, HttpServletRequest req, HttpServletResponse res) throws IOException, CmsException { if (m_enabled) { if (canSendLastModifiedHeader(resource, req, res)) { // no image processing required at all return; } // get the scale information from the request CmsImageScaler scaler = new CmsImageScaler(req, m_maxScaleSize, m_maxBlurSize); // load the file from the cache CmsFile file = getScaledImage(cms, resource, scaler); // now perform standard load operation inherited from dump loader super.load(cms, file, req, res); } else { // scaling is disabled super.load(cms, resource, req, res); } }