org.apache.commons.launcher
Class ParentListener
Thread
org.apache.commons.launcher.ParentListener
public class ParentListener
extends Thread
A class for detecting if the parent JVM that launched this process has
terminated.
ParentListener(String path) - Validates and caches a lock file created by the parent JVM.
|
void | run() - Periodically check that the parent JVM has not terminated.
|
ParentListener
public ParentListener(String path)
throws IOException
Validates and caches a lock file created by the parent JVM.
path
- the lock file that the parent JVM has an open
FileOutputStream
run
public void run()
Periodically check that the parent JVM has not terminated. On all
platforms other than Windows, this method will check that System.in has
not been closed. On Windows NT, 2000, and XP the lock file specified in
the
ParentListener(String)
constructor is monitored as reading
System.in will block the entire process on Windows machines that use
some versions of Unix shells such as MKS, etc. No monitoring is done
on Window 95, 98, and ME.
Copyright (c) 2001-2002 - Apache Software Foundation