The Java Swing framework is an example of an architecture and is implemented in the org.eclipse.actf.validation.javapp.SwingGuiModel class. This model implementation is a framework for inspecting and validating hierarchical structures of Swing GUI components. The implementation of the aforementioned methods is obvious to any developer familiar with Swing.
The method isVisible()
determines whether the component is visible
and it's parent window is also visible.
The method requestFocusFor(Object)
(in AwtGuiModel,
which SwingGuiModel extends) calls requestFocusInWindow()
on the component.
The method invokeOnUIThread(Runnable)
calls
SwingUtilities.invokeAndWait(Runnable)
while the method
asyncInvokeOnUIThread(Runnable)
calls
SwingUtilities.invokeLater(Runnable)
.
The Java AWT architecture is quite similar to the Java Swing architecture from ACTF's point of view. The construction, traversal, or inspection of GUI components in each architecture is nearly identical. The only difference lies in the packages imported and the aliases used by the architectures.