Package ej.mwt.stylesheet.selector.combinator

## Class DescendantCombinator

- java.lang.Object
- - ej.mwt.stylesheet.selector.combinator.Combinator
  - - ej.mwt.stylesheet.selector.combinator.DescendantCombinator

- All Implemented Interfaces:
    `Selector`

      public class DescendantCombinator
      extends Combinator

  A descendant combinator selects by checking the widget hierarchy.

  Equivalent to `widget widget` selector in CSS.

  See Also:
    `Widget.getParent()`

- - ### Constructor Summary

    Constructors
    Constructor | Description
    --- | ---
    `DescendantCombinator​(Selector selector1, Selector selector2)` | Creates a descendant combinator.

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `boolean` | `appliesToWidget​(Widget widget)` | Checks whether or not this selector applies to the given widget.

    - ### Methods inherited from class ej.mwt.stylesheet.selector.combinator.Combinator

      `equals, getFirstSelector, getSecondSelector, getSpecificity, hashCode`

    - ### Methods inherited from class java.lang.Object

      `clone, getClass, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### DescendantCombinator

          public DescendantCombinator​(Selector selector1,
                                      Selector selector2)

      Creates a descendant combinator.
      Parameters:
        `selector1` - the first selector.
        `selector2` - the second selector.

  - ### Method Detail

    - #### appliesToWidget

          public boolean appliesToWidget​(Widget widget)

      Description copied from interface: `Selector`
      Checks whether or not this selector applies to the given widget.
      Parameters:
        `widget` - the widget to test.
      Returns:
        `true` if this selectors applies to the given widget, `false` otherwise.