Package com.helger.css.decl.visit
Class AbstractModifyingCSSUrlVisitor
java.lang.Object
com.helger.css.decl.visit.DefaultCSSUrlVisitor
com.helger.css.decl.visit.AbstractModifyingCSSUrlVisitor
- All Implemented Interfaces:
ICSSUrlVisitor
Abstract
ICSSUrlVisitor that modifies all URLs according to an
abstract rule- Author:
- Philip Helger
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected abstract StringgetModifiedURI(String sURI) voidonImport(CSSImportRule aImportRule) Called on CSS import statement.voidonUrlDeclaration(ICSSTopLevelRule aTopLevelRule, CSSDeclaration aDeclaration, CSSExpressionMemberTermURI aExprTerm) Called on a CSS declaration value that contains an URL.
Note: for keyframes it is currently not possible to retrieve the keyframes block to which the declaration belongs.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.helger.css.decl.visit.ICSSUrlVisitor
begin, end
-
Constructor Details
-
AbstractModifyingCSSUrlVisitor
public AbstractModifyingCSSUrlVisitor()
-
-
Method Details
-
getModifiedURI
-
onImport
Description copied from interface:ICSSUrlVisitorCalled on CSS import statement. UseaImportRule.getLocation()to retrieve the imported URL.- Specified by:
onImportin interfaceICSSUrlVisitor- Overrides:
onImportin classDefaultCSSUrlVisitor- Parameters:
aImportRule- Other imported CSS. Nevernull.
-
onUrlDeclaration
public void onUrlDeclaration(@Nullable ICSSTopLevelRule aTopLevelRule, @Nonnull CSSDeclaration aDeclaration, @Nonnull CSSExpressionMemberTermURI aExprTerm) Description copied from interface:ICSSUrlVisitorCalled on a CSS declaration value that contains an URL.
Note: for keyframes it is currently not possible to retrieve the keyframes block to which the declaration belongs.- Specified by:
onUrlDeclarationin interfaceICSSUrlVisitor- Overrides:
onUrlDeclarationin classDefaultCSSUrlVisitor- Parameters:
aTopLevelRule- Top level rule of the URL. May benullwhen a declaration list is handled.aDeclaration- Declaration of the URL. Nevernull.aExprTerm- The URI term from the current expression. Nevernull.
-