Simple Question

Hi all,

Please excuse me for such simple questions:

I was studying and reading and I noticed many swing applications launch the program by the following code:

publicstaticvoid main(String[] args){

javax.swing.SwingUtilities.invokeLater(new Runnable(){

publicvoid run(){

GUI gui =new GUI();

}

});

Apart from theGUI gui = new GUI(); andpublic static void main (String[] args) What does the code do?

Thanks :)

[871 byte] By [Xenobiusa] at [2007-11-27 1:11:05]
# 1
Have a look at the API (and the suggested threads tutorial there!): http://java.sun.com/j2se/1.4.2/docs/api/javax/swing/SwingUtilities.html#invokeLater(java.lang.Runnable)
prometheuzza at 2007-7-11 23:46:24 > top of Java-index,Java Essentials,New To Java...
# 2
Cool thanks man :PI managed :)
Xenobiusa at 2007-7-11 23:46:24 > top of Java-index,Java Essentials,New To Java...
# 3
> Cool thanks man :P> > I managed :)No problem.; )
prometheuzza at 2007-7-11 23:46:24 > top of Java-index,Java Essentials,New To Java...