ro.isdc.wro.model.resource.processor.impl.css
Class DuplicatesAwareCssDataUriPreProcessor
java.lang.Object
ro.isdc.wro.model.resource.processor.impl.css.AbstractCssUrlRewritingProcessor
ro.isdc.wro.model.resource.processor.impl.css.CssDataUriPreProcessor
ro.isdc.wro.model.resource.processor.impl.css.DuplicatesAwareCssDataUriPreProcessor
- All Implemented Interfaces:
- ImportAware, ResourcePostProcessor, ResourcePreProcessor
public class DuplicatesAwareCssDataUriPreProcessor
- extends CssDataUriPreProcessor
Similar to CssDataUriPreProcessor
which instead of replacing a url blindly with dataUri, is is smart enough to
detect duplicated image url and avoid replacing it with dataUri.
- Author:
- Alex Objelean
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ALIAS_DUPLICATE
public static final String ALIAS_DUPLICATE
- See Also:
- Constant Field Values
DuplicatesAwareCssDataUriPreProcessor
public DuplicatesAwareCssDataUriPreProcessor()
replaceImageUrl
protected final String replaceImageUrl(String cssUri,
String imageUrl)
- Replace provided url with the new url if needed.
- Overrides:
replaceImageUrl
in class CssDataUriPreProcessor
- Parameters:
imageUrl
- to replace.cssUri
- Uri of the parsed css.
- Returns:
- replaced url.
onProcessCompleted
protected void onProcessCompleted()
- Invoked when the process operation is completed. Useful to invoke some post processing logic or for custom logging.
- Overrides:
onProcessCompleted
in class AbstractCssUrlRewritingProcessor
Copyright © 2008-2013. All Rights Reserved.