- java.lang.Object
-
- org.testfx.service.finder.impl.NodeFinderImpl
-
- All Implemented Interfaces:
NodeFinder
public class NodeFinderImpl extends Object implements NodeFinder
-
-
Constructor Summary
Constructors Constructor Description NodeFinderImpl(WindowFinder windowFinder)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description NodeQueryfrom(Collection<Node> parentNodes)Returns aNodeQuerythat stores the given parentNodes collection.NodeQueryfrom(Node... parentNodes)Returns aNodeQuerythat stores the given parentNodesNodeQueryfrom(NodeQuery nodeQuery)Returns a newNodeQuerythat stores all the parentNodes from the given nodeQuery (essentially, it creates a copy/clone).NodeQueryfromAll()Returns aNodeQuerythat stores all the root nodes of all windows viaWindowFinder.listTargetWindows()NodeQuerylookup(String query)Returns aNodeQuerythat stores all the root nodes that meet the given query<T extends Node>
NodeQuerylookup(Predicate<T> predicate)Returns aNodeQuerythat stores all the root nodes that pass the given predicate<T> NodeQuerylookup(org.hamcrest.Matcher<T> matcher)Returns aNodeQuerythat stores all the root nodes that match the given matcher.NoderootNode(Node node)Returns the node's scene's root nodeNoderootNode(Scene scene)Returns the scene's root nodeNoderootNode(Window window)Returns the window's scene's root node.
-
-
-
Constructor Detail
-
NodeFinderImpl
public NodeFinderImpl(WindowFinder windowFinder)
-
-
Method Detail
-
lookup
public NodeQuery lookup(String query)
Description copied from interface:NodeFinderReturns aNodeQuerythat stores all the root nodes that meet the given query- Specified by:
lookupin interfaceNodeFinder- See Also:
NodeQuery.lookup(String)
-
lookup
public <T> NodeQuery lookup(org.hamcrest.Matcher<T> matcher)
Description copied from interface:NodeFinderReturns aNodeQuerythat stores all the root nodes that match the given matcher.- Specified by:
lookupin interfaceNodeFinder- See Also:
NodeQuery.lookup(Matcher)
-
lookup
public <T extends Node> NodeQuery lookup(Predicate<T> predicate)
Description copied from interface:NodeFinderReturns aNodeQuerythat stores all the root nodes that pass the given predicate- Specified by:
lookupin interfaceNodeFinder- See Also:
NodeQuery.lookup(Predicate)
-
fromAll
public NodeQuery fromAll()
Description copied from interface:NodeFinderReturns aNodeQuerythat stores all the root nodes of all windows viaWindowFinder.listTargetWindows()- Specified by:
fromAllin interfaceNodeFinder
-
from
public NodeQuery from(Node... parentNodes)
Description copied from interface:NodeFinderReturns aNodeQuerythat stores the given parentNodes- Specified by:
fromin interfaceNodeFinder
-
from
public NodeQuery from(Collection<Node> parentNodes)
Description copied from interface:NodeFinderReturns aNodeQuerythat stores the given parentNodes collection.- Specified by:
fromin interfaceNodeFinder
-
from
public NodeQuery from(NodeQuery nodeQuery)
Description copied from interface:NodeFinderReturns a newNodeQuerythat stores all the parentNodes from the given nodeQuery (essentially, it creates a copy/clone).- Specified by:
fromin interfaceNodeFinder
-
rootNode
public Node rootNode(Window window)
Description copied from interface:NodeFinderReturns the window's scene's root node.- Specified by:
rootNodein interfaceNodeFinder
-
rootNode
public Node rootNode(Scene scene)
Description copied from interface:NodeFinderReturns the scene's root node- Specified by:
rootNodein interfaceNodeFinder
-
rootNode
public Node rootNode(Node node)
Description copied from interface:NodeFinderReturns the node's scene's root node- Specified by:
rootNodein interfaceNodeFinder
-
-