SwingUtilities vs EventQueue

0

Czy możecie mi wyjaśnić jaka jest różnica między SwingUtilities.invokeLater a EventQueue.invokeLater?
Pls.

0

Kod SwingUtilities.java:

    (...)
    public static void invokeLater(Runnable doRun) {
        EventQueue.invokeLater(doRun);
    }
    (...)
    public static void invokeAndWait(final Runnable doRun)
        throws InterruptedException, InvocationTargetException
    {
        EventQueue.invokeAndWait(doRun);
    }
    (...)
0

Wiem gdzie tego szukać w NB navigate->goToSource
Liczyłem na coś w formie tekstowej:)

0

OK. To wycinki z JavaDocu:

(...)
As of 1.3 this method is just a cover for java.awt.EventQueue.invokeLater().
(...)
As of 1.3 this method is just a cover for java.awt.EventQueue.invokeAndWait().
(...)

Nie wiem jak można być bardziej sugestywnym. Mają napisać: "There's no f**ing difference between SwingUtitlites.invokeLater and EventQueue.invokeLater as of 1.3"?

0

Miałem napisać że nie ma różnicy po tym co napisałeś w pierwszym poście ale gdybym się mylił to było by mi głupio.
A tak to dzięki.

1 użytkowników online, w tym zalogowanych: 0, gości: 1