public final class ComponentPreconditions extends Object
Component.| Modifier and Type | Method and Description |
|---|---|
static void |
checkEnabled(Component c)
Verifies that the
Component is enabled. |
static void |
checkEnabledAndShowing(Component c)
Verifies that the
Component is enabled and showing. |
static void |
checkShowing(Component c)
Verifies that the
Component is showing on the screen. |
@RunsInCurrentThread public static void checkEnabledAndShowing(@Nonnull Component c)
Verifies that the Component is enabled and showing.
Note: This method is accessed in the current executing thread. Such thread may or may not be the event dispatch thread (EDT.) Client code must call this method from the EDT.
c - the target component.IllegalStateException - if the Component is disabled.IllegalStateException - if the Component is not showing on the screen.@RunsInCurrentThread public static void checkEnabled(@Nonnull Component c)
Verifies that the Component is enabled.
Note: This method is accessed in the current executing thread. Such thread may or may not be the event dispatch thread (EDT.) Client code must call this method from the EDT.
c - the target component.IllegalStateException - if the Component is disabled.@RunsInCurrentThread public static void checkShowing(@Nonnull Component c)
Verifies that the Component is showing on the screen.
Note: This method is accessed in the current executing thread. Such thread may or may not be the event dispatch thread (EDT.) Client code must call this method from the EDT.
c - the target component.IllegalStateException - if the Component is not showing on the screen.Copyright © 2014 AssertJ. All rights reserved.