How to determine when an application started using java reflection has completed -


I have a Java program that can find and apply the main (string [] algues) method of another Java program Uses reflections. This other program is usually a swing app that produces its own threads. I was wondering if there was a way to decide when this 'program' would end. I'm not sure that it is anyway to find out because it is implemented in the same place as a host program. The present method is only to check whether any of the open frames are not ours, it is not the biggest solution.

Edit: It seems that the answer is a dual approach. First create a thread group and launch that child's program in the thread that is a member of that group. Then make sure to check the frame.getFrames () if any frame belongs to the child.

Thanks, - Sandro

Set the child app to a different one (possibly : Set this as the best daemon thread group) and periodically check whether there are any running threads or subgroups in it.


Comments

Popular posts from this blog

c++ - Linux and clipboard -

What is expire header and how to achive them in ASP.NET and PHP? -

sql server - How can I determine which of my SQL 2005 statistics are unused? -