Package org.fest.swing.driver
Class JMenuItemMatcher
java.lang.Object
org.fest.swing.driver.JMenuItemMatcher
- All Implemented Interfaces:
ComponentMatcher
Matches a
JMenuItem given a simple label or a menu path of the format "menu|submenu|menuitem",
for example "File|Open|Can of worms". Adapted from Abbot's own JMenuItemMatcher.-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
-
Field Details
-
SEPARATOR
- See Also:
-
label
-
-
Constructor Details
-
JMenuItemMatcher
Creates a newJMenuItemMatcher.- Parameters:
path- the path of the menu to match.
-
-
Method Details
-
matches
Indicates whether the given component is awhose text matches the path specified in this matcher.JMenuItemNote: This method is not executed in the event dispatch thread (EDT.) Clients are responsible for invoking this method in the EDT.
- Specified by:
matchesin interfaceComponentMatcher- Parameters:
c- the component to verify.- Returns:
trueif the component matches,falseotherwise.
-
pathOf
-
parentOrInvokerOf
-
toString
-