Package org.fest.swing.core

Examples of org.fest.swing.core.TypeMatcher


   * @throws ActionFailedException if an editor for the given cell cannot be found or cannot be activated.
   */
  @RunsInEDT
  protected final @Nullable <T extends Component> T waitForEditorActivation(@Nonnull JTable table, int row, int column,
      @Nonnull Class<T> supportedType) {
    return waitForEditorActivation(new TypeMatcher(supportedType, true), table, row, column, supportedType);
  }
View Full Code Here


  /** {@inheritDoc} */
  @RunsInEDT
  @Override
  public @Nonnull DialogFixture dialog(@Nonnull Timeout timeout) {
    TypeMatcher matcher = new TypeMatcher(Dialog.class, requireShowing());
    return findDialog(matcher, timeout);
  }
View Full Code Here

  /** {@inheritDoc} */
  @RunsInEDT
  @Override
  public @Nonnull JFileChooserFixture fileChooser(@Nonnull Timeout timeout) {
    TypeMatcher matcher = new TypeMatcher(JFileChooser.class, requireShowing());
    return findFileChooser(matcher, timeout);
  }
View Full Code Here

  /** {@inheritDoc} */
  @RunsInEDT
  @Override
  public @Nonnull JOptionPaneFixture optionPane(@Nonnull Timeout timeout) {
    TypeMatcher matcher = new TypeMatcher(JOptionPane.class, requireShowing());
    String description = "option pane to be found using matcher " + matcher;
    ComponentFoundCondition condition = new ComponentFoundCondition(description, robot().finder(), matcher);
    pause(condition, timeout);
    JOptionPane optionPane = (JOptionPane) condition.found();
    return new JOptionPaneFixture(robot(), checkNotNull(optionPane));
View Full Code Here

   * Creates a new {@link ComponentFinderTemplate}.
   *
   * @param componentType the type of the {@code Component} to find.
   */
  protected ComponentFinderTemplate(@Nonnull Class<? extends T> componentType) {
    this(new TypeMatcher(componentType, true));
  }
View Full Code Here

    return dialog(DEFAULT_DIALOG_LOOKUP_TIMEOUT);
  }

  /** {@inheritDoc} */
  public DialogFixture dialog(Timeout timeout) {
    TypeMatcher matcher = new TypeMatcher(Dialog.class, requireShowing());
    return findDialog(matcher, timeout);
  }
View Full Code Here

    return fileChooser(DEFAULT_DIALOG_LOOKUP_TIMEOUT);
  }

  /** {@inheritDoc} */
  public JFileChooserFixture fileChooser(Timeout timeout) {
    TypeMatcher matcher = new TypeMatcher(JFileChooser.class, requireShowing());
    return findFileChooser(matcher, timeout);
  }
View Full Code Here

    return optionPane(DEFAULT_DIALOG_LOOKUP_TIMEOUT);
  }

  /** {@inheritDoc} */
  public JOptionPaneFixture optionPane(Timeout timeout) {
    TypeMatcher matcher = new TypeMatcher(JOptionPane.class, requireShowing());
    String description = "option pane to be found using matcher " + matcher;
    ComponentFoundCondition condition = new ComponentFoundCondition(description, robot.finder(), matcher);
    pause(condition, timeout);
    return new JOptionPaneFixture(robot, (JOptionPane)condition.found());
  }
View Full Code Here

     * @param dialogClass dialog class
     */
    protected void assertComponentDisplayed(Class<? extends Component> componentClass) {
        Pause.pause(new ComponentFoundCondition("component to be displayed",
                BasicComponentFinder.finderWithCurrentAwtHierarchy(),
                new TypeMatcher(componentClass, true)),
                DISPLAY_TIMEOUT);
    }
View Full Code Here

TOP

Related Classes of org.fest.swing.core.TypeMatcher

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.