jodd.lagarto.csselly.selector
Class PseudoClass

java.lang.Object
  extended by jodd.lagarto.csselly.selector.PseudoClass
Direct Known Subclasses:
PseudoClass.BUTTON, PseudoClass.CHECKBOX, PseudoClass.CHECKED, PseudoClass.EMPTY, PseudoClass.EVEN, PseudoClass.FILE, PseudoClass.FIRST, PseudoClass.FIRST_CHILD, PseudoClass.FIRST_OF_TYPE, PseudoClass.HEADER, PseudoClass.IMAGE, PseudoClass.INPUT, PseudoClass.LAST, PseudoClass.LAST_CHILD, PseudoClass.LAST_OF_TYPE, PseudoClass.ODD, PseudoClass.ONLY_CHILD, PseudoClass.ONLY_OF_TYPE, PseudoClass.PARENT, PseudoClass.PASSWORD, PseudoClass.RADIO, PseudoClass.RESET, PseudoClass.ROOT, PseudoClass.SELECTED, PseudoClass.SUBMIT, PseudoClass.TEXT

public abstract class PseudoClass
extends java.lang.Object

Pseudo classes.


Nested Class Summary
static class PseudoClass.BUTTON
          Selects all button elements and elements of type button.
static class PseudoClass.CHECKBOX
          Selects all elements of type checkbox.
static class PseudoClass.CHECKED
          Selects all elements that are checked.
static class PseudoClass.EMPTY
          Represents an element that has no children at all.
static class PseudoClass.EVEN
          Selects even elements, zero-indexed.
static class PseudoClass.FILE
          Selects all elements of type file.
static class PseudoClass.FIRST
          Selects the first matched element.
static class PseudoClass.FIRST_CHILD
          Same as :nth-child(1).
static class PseudoClass.FIRST_OF_TYPE
          Same as :nth-of-type(1).
static class PseudoClass.HEADER
          Selects all elements that are headers, like h1, h2, h3 and so on.
static class PseudoClass.IMAGE
          Selects all elements of type image.
static class PseudoClass.INPUT
          Selects all input, textarea, select and button elements.
static class PseudoClass.LAST
          Selects the last matched element.
static class PseudoClass.LAST_CHILD
          Same as :nth-last-child(1).
static class PseudoClass.LAST_OF_TYPE
          Same as :nth-last-of-type(1).
static class PseudoClass.ODD
          Selects odd elements, zero-indexed.
static class PseudoClass.ONLY_CHILD
          Represents an element that has a parent element and whose parent element has no other element children.
static class PseudoClass.ONLY_OF_TYPE
          Represents an element that has a parent element and whose parent element has no other element children with the same expanded element name.
static class PseudoClass.PARENT
          Select all elements that are the parent of another element, including text nodes.
static class PseudoClass.PASSWORD
          Selects all elements of type password.
static class PseudoClass.RADIO
          Selects all elements of type radio.
static class PseudoClass.RESET
          Selects all elements of type reset.
static class PseudoClass.ROOT
          Represents an element that is the root of the document.
static class PseudoClass.SELECTED
          Selects all elements that are selected.
static class PseudoClass.SUBMIT
          Selects all elements of type submit.
static class PseudoClass.TEXT
          Selects all elements of type text.
 
Constructor Summary
PseudoClass()
           
 
Method Summary
 java.lang.String getPseudoClassName()
          Returns pseudo-class name from simple class name.
 boolean match(java.util.LinkedList<Node> currentResults, Node node, int index)
          Returns true if node matches the pseudoclass within current results.
abstract  boolean match(Node node)
          Returns true if node matches the pseudoclass.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PseudoClass

public PseudoClass()
Method Detail

match

public abstract boolean match(Node node)
Returns true if node matches the pseudoclass.


match

public boolean match(java.util.LinkedList<Node> currentResults,
                     Node node,
                     int index)
Returns true if node matches the pseudoclass within current results.


getPseudoClassName

public java.lang.String getPseudoClassName()
Returns pseudo-class name from simple class name.



Copyright © 2003-2012 Jodd Team