Class PseudoClasses.ODD

  • Enclosing interface:
    PseudoClasses

    public static class PseudoClasses.ODD
    extends PseudoClass
    Selects odd elements, zero-indexed.
    • Constructor Summary

      Constructors 
      Constructor Description
      ODD()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean match​(Node node)
      Returns true if node matches the pseudo-class.
      boolean matchInRange​(java.util.List<Node> matchedResults, Node node, int index)
      Returns true if node matches the pseudo-class within current results.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • ODD

        public ODD()
    • Method Detail

      • match

        public boolean match​(Node node)
        Description copied from class: PseudoClass
        Returns true if node matches the pseudo-class.
        Specified by:
        match in class PseudoClass
      • matchInRange

        public boolean matchInRange​(java.util.List<Node> matchedResults,
                                    Node node,
                                    int index)
        Description copied from class: PseudoClass
        Returns true if node matches the pseudo-class within current results. This match is all about the range and node position in it. By default, returns true.
        Overrides:
        matchInRange in class PseudoClass