Class Matcher.Mapper

  • Enclosing class:
    Matcher

    class Matcher.Mapper
    extends java.lang.Object
    Mapper represents a local CSS for a Node that is used to match the Node's children.
    • Field Detail

      • axes

        private final java.util.List<Selector> axes
      • pseudoSelectors

        private final java.util.Map<java.lang.String,​java.util.List<Selector>> pseudoSelectors
      • mappedSelectors

        private final java.util.List<Selector> mappedSelectors
      • children

        private java.util.Map<java.lang.String,​Matcher.Mapper> children
    • Constructor Detail

      • Mapper

        Mapper​(java.util.Collection<Selector> selectors)
      • Mapper

        private Mapper​(java.util.List<Selector> axes,
                       java.util.List<Selector> mappedSelectors,
                       java.util.Map<java.lang.String,​java.util.List<Selector>> pseudoSelectors)
    • Method Detail

      • mapChild

        Matcher.Mapper mapChild​(java.lang.Object e)
        Side effect: creates and stores a Mapper for the element
        Parameters:
        e -
        Returns:
        The selectors that matched, sorted according to specificity (more correct: preserves the sort order from Matcher creation)
      • getCascadedStyle

        CascadedStyle getCascadedStyle​(java.lang.Object e)
      • getPECascadedStyle

        public CascadedStyle getPECascadedStyle​(java.lang.Object e,
                                                java.lang.String pseudoElement)
        May return null. We assume that restyle has already been done by a getCascadedStyle if necessary.