The Artima Developer Community
Sponsored Link

Legacy Java Answers Forum
October 2001

Advertisement

Advertisement

This page contains an archived post to the Java Answers Forum made prior to February 25, 2002. If you wish to participate in discussions, please visit the new Artima Forums.

Message:

Detecting Programs

Posted by Matt Gerrans on October 18, 2001 at 5:26 PM

I think this is a operating system-specific thing. I know how you would do it in Windows or Unix, for instance, but it would be different on Mac (actually OS X is Unix) and others. In any case, you would need native methods to access the OS-specific implementation...

If you also writing (in C/C++ or whatever) the program that you are calling, you can make it single-instance (easy to do with a mutex), so that you can just exec() it whenever you need it and if it is already running, it won't run again.

- mfg

> I want to know if it is possible to detect is a particular application is loaded and running in memory. The exec call allows you to run system programs, but is it possible program has already been loaded and running?





Replies:

Sponsored Links



Google
  Web Artima.com   
Copyright © 1996-2009 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use - Advertise with Us