Class DefaultStyleResolver
java.lang.Object
org.pentaho.reporting.libraries.css.resolver.impl.AbstractStyleResolver
org.pentaho.reporting.libraries.css.resolver.impl.DefaultStyleResolver
- All Implemented Interfaces:
StyleResolver
A cascading style resolver. This resolver follows the cascading rules as outlined by the Cascading Stylesheet
Standard.
- Author:
- Thomas Morgner
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
initialize
(DocumentContext layoutProcess) boolean
isPseudoElementStyleResolvable
(LayoutElement element, String pseudo) Performs tests, whether there is a pseudo-element definition for the given element.protected void
resolveOutOfContext
(LayoutElement element) resolvePageStyle
(CSSValue pageName, PseudoPage[] pseudoPages, PageAreaType pageArea) void
resolveStyle
(LayoutElement element) Resolves the style.Methods inherited from class org.pentaho.reporting.libraries.css.resolver.impl.AbstractStyleResolver
containsResolveableFunction, copyStyleInformation, getDocumentContext, getInitialStyle, getKeys, getNamespaces, loadInitialStyle, resolveValue
-
Constructor Details
-
DefaultStyleResolver
public DefaultStyleResolver()
-
-
Method Details
-
initialize
- Specified by:
initialize
in interfaceStyleResolver
- Overrides:
initialize
in classAbstractStyleResolver
-
resolveOutOfContext
- Specified by:
resolveOutOfContext
in classAbstractStyleResolver
-
isPseudoElementStyleResolvable
Performs tests, whether there is a pseudo-element definition for the given element. The element itself can be a pseudo-element as well.- Parameters:
element
-pseudo
-- Returns:
-
resolveStyle
Resolves the style. This is guaranteed to be called in the order of the document elements traversing the document tree using the 'deepest-node-first' strategy. (8% just for the first class calls (not counting the calls comming from resolveAnonymous (which is another 6%))- Parameters:
element
- the elemen that should be resolved.
-
deriveInstance
-
resolvePageStyle
public LayoutStyle resolvePageStyle(CSSValue pageName, PseudoPage[] pseudoPages, PageAreaType pageArea)
-