concurrency « Thread « Java Swing Q&A





1. Scheduling Swingworker threads    stackoverflow.com

I have a 2 processes to perform in my swing application, one to fill a list, and one to do operations on each element on the list. I've just moved the ...

2. Swing: Passing a value back to the UI from a scheduled thread    stackoverflow.com

I have a system tray UI in Java that requires a schedule database poll. What is the best method for spawning a new thread and notifying the UI? I'm ...

3. Occasional InterruptedException when quitting a Swing application    stackoverflow.com

I recently updated my computer to a more powerful one, with a quad-core hyperthreading processor (i7), thus plenty of real concurrency available. Now I'm occasionally getting the following error when quitting ...

4. Displaying JWindow in the event dispatching thread    stackoverflow.com

What I am trying to do is have a small splash screen appear while my program is loading something. This is what I have:

SplashScreen.showSplashScreen();
// Do stuff that takes time.
SplashScreen.hideSplashScreen();
All the showSplashScreen() ...

5. Where can I find good advanced Java video tutorials?    stackoverflow.com

I have found many good sites offering video tutorials on basic concepts in Java. I was wondering if anyone had any links to some tutorials on topics such as Concurrent programming ...

6. Swing - Concurrency in the typical desktop application    stackoverflow.com

This is probably a broad question but I'd like to know where concurrency is typically used for a mono user desktop application. How do you spot a case (at design stage, ...

7. Explain what the following code does?    stackoverflow.com

java.awt.EventQueue.invokeLater(new Runnable() {
    public void run() {
        new NewJFrame().setVisible(true);
    }
});
Please tell me what does the above code does ...

8. Java Swing Threading Problem    stackoverflow.com

I have a problem related to using threads in swing. I will first explain the problem, and then I will post my code. The problem is the following. I have two classes, one ...

9. Ignoring events that fire repeatedly    stackoverflow.com

I have some code that responds to a PropertyChangeEvent. The problem with this event is that it can be fired in succession a few times or not at all. It is ...





10. How to share data with two(2) SwingWorker class in Java    stackoverflow.com

I have two SwingWorker class: FileLineCounterThread and FileDivisionThread I will execute the two threads. When the lines counting thread finishes, it will pass the result to File Division thread. I do not have ...

11. Simple server/client GUI Communication    stackoverflow.com

I have an application setup in this manner: The server listens for a incoming connection from the client, and when the client connects, both the server and the client spawn a new ...

12. How do I simulate a buffered peripheral device with SwingWorker?    stackoverflow.com

I'm using this exercise as a pedagogical tool to help me burn in some Java GUI programming concepts. What I'm looking for is a general understanding, rather than a detailed ...

13. AspectJ EDT-Checker Code Question    stackoverflow.com

I am currently using Alexander Potochkin's AspectJ EDTChecker code (relevant code at bottom of post). This code (from what little I understand of AspectJ) complains on any JComponent method call ...

14. Using SwingWorker to implement a UDP Client/Server    stackoverflow.com

Trying to write a UDP client-server application using Swing. Each instance of the client should be able to send messages to the Server (from the event dispatch thread) and also continuously ...

15. Wait for SwingWorker to finish    stackoverflow.com

I want to wait for my SwingWorker to finish working, and then I want to execute another SwingWorker. In this case Encrypteer3 is a class that extends the SwingWorker. My code:

  ...

16. Concurrency in SWING    coderanch.com

That "createAndShowGUI()" method will assemble the frames, panels, buttons, menus, etc, call setVisible(true), and return. It won't keep running forever. Swing GUIs are "event driven", which means that when the user clicks a button (for example), one of the event handler methods you supply gets called on that event thread to react to that click. It's these event handler methods that ...