![JAR search and dependency download from the Maven repository](/logo.png)
org.daisy.pipeline.css.StyleAccessor Maven / Gradle / Ivy
package org.daisy.pipeline.css;
import java.util.Optional;
import org.daisy.common.xpath.saxon.ExtensionFunctionProvider;
import org.daisy.common.xpath.saxon.ReflexiveExtensionFunctionProvider;
import org.osgi.service.component.annotations.Component;
import org.w3c.dom.Element;
public abstract class StyleAccessor {
@Component(
name = "StyleAccesor",
service = { ExtensionFunctionProvider.class }
)
public static class Provider extends ReflexiveExtensionFunctionProvider {
public Provider() {
super(StyleAccessor.class);
}
}
/**
* Get the specified
* value of a CSS property and element.
*/
public abstract Optional get(Element element, String property);
/**
* Test whether an element matches a CSS selector.
*
* @throws IllegalArgumentException if the selector can not be compiled
*/
public abstract boolean matches(Element element, String selector);
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy