|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--javax.realtime.POSIXSignalHandler
Use instances of AsyncEvent
to handle POSIX signals. Usage:
POSIXSignalHandler.addHandler(SIGINT, intHandler);This class is required to be implemented only if the underlying operating system supports POSIX signals.
Field Summary | |
static int |
SIGABRT
Used by abort, replace SIGIOT in the future. |
static int |
SIGALRM
Alarm clock. |
static int |
SIGBUS
Bus error. |
static int |
SIGCANCEL
Thread cancellation signal used by libthread. |
static int |
SIGCHLD
Child status change alias (POSIX). |
static int |
SIGCLD
Child status change. |
static int |
SIGCONT
Stopped process has been continued. |
static int |
SIGEMT
EMT instruction. |
static int |
SIGFPE
Floating point exception. |
static int |
SIGFREEZE
Special signal used by CPR. |
static int |
SIGHUP
Hangup. |
static int |
SIGILL
Illegal instruction (not reset when caught). |
static int |
SIGINT
Interrupt (rubout). |
static int |
SIGIO
Socket I/O possible (SIGPOLL alias). |
static int |
SIGIOT
IOT instruction. |
static int |
SIGKILL
Kill (cannot be caught or ignored). |
static int |
SIGLOST
Resource lost (e.g., record-lock lost). |
static int |
SIGLWP
Special signal used by thread library. |
static int |
SIGPIPE
Write on a pipe with no one to read it. |
static int |
SIGPOLL
Pollable event occurred. |
static int |
SIGPROF
Profiling timer expired. |
static int |
SIGPWR
Power-fail restart. |
static int |
SIGQUIT
Quit (ASCII FS). |
static int |
SIGSEGV
Segmentation violation. |
static int |
SIGSTOP
Stop (cannot be caught or ignored). |
static int |
SIGSYS
Bad argument to system call. |
static int |
SIGTERM
Software termination signal from kill. |
static int |
SIGTHAW
Special signal used by CPR. |
static int |
SIGTRAP
Trace trap (not reset when caught). |
static int |
SIGTSTP
User stop requested from tty. |
static int |
SIGTTIN
Background tty read attempted. |
static int |
SIGTTOU
Background tty write attempted. |
static int |
SIGURG
Urgent socket condition. |
static int |
SIGUSR1
User defined signal = 1. |
static int |
SIGUSR2
User defined signal = 2. |
static int |
SIGVTALRM
Virtual timer expired. |
static int |
SIGWAITING
Process's lwps are blocked. |
static int |
SIGWINCH
Window size change. |
static int |
SIGXCPU
Exceeded cpu limit. |
static int |
SIGXFSZ
Exceeded file size limit. |
Constructor Summary | |
POSIXSignalHandler()
|
Method Summary | |
static void |
addHandler(int signal,
AsyncEventHandler handler)
Add the given AsyncEventHandler to the list of handlers of the AsyncEvent of the given signal. |
static void |
removeHandler(int signal,
AsyncEventHandler handler)
Remove the given AsyncEventHandler to the list of handlers
of the AsyncEvent of the given signal. |
static void |
setHandler(int signal,
AsyncEventHandler handler)
Set the given AsyncEventHandler as the handler of the AsyncEvent of the given signal. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final int SIGHUP
public static final int SIGINT
public static final int SIGQUIT
public static final int SIGILL
public static final int SIGTRAP
public static final int SIGIOT
public static final int SIGABRT
public static final int SIGEMT
public static final int SIGFPE
public static final int SIGKILL
public static final int SIGBUS
public static final int SIGSEGV
public static final int SIGSYS
public static final int SIGPIPE
public static final int SIGALRM
public static final int SIGTERM
public static final int SIGUSR1
public static final int SIGUSR2
public static final int SIGCLD
public static final int SIGCHLD
public static final int SIGPWR
public static final int SIGWINCH
public static final int SIGURG
public static final int SIGPOLL
public static final int SIGIO
public static final int SIGSTOP
public static final int SIGTSTP
public static final int SIGCONT
public static final int SIGTTIN
public static final int SIGTTOU
public static final int SIGVTALRM
public static final int SIGPROF
public static final int SIGXCPU
public static final int SIGXFSZ
public static final int SIGWAITING
public static final int SIGLWP
public static final int SIGFREEZE
public static final int SIGTHAW
public static final int SIGCANCEL
public static final int SIGLOST
Constructor Detail |
public POSIXSignalHandler()
Method Detail |
public static void addHandler(int signal, AsyncEventHandler handler)
AsyncEventHandler
to the list of handlers of the AsyncEvent
of the given signal.signal
- One of the POSIX signals from this (e.g., this.SIGLOST
). If the value given to
signal
is not one of the POSIX signals then an IllegalArgumentException
will be thrown.handler
- An AsyncEventHandler
which will be scheduled when the given signal occurs.public static void removeHandler(int signal, AsyncEventHandler handler)
AsyncEventHandler
to the list of handlers
of the AsyncEvent
of the given signal.signal
- One of the POSIX signals from this (e.g., this.SIGLOST
). If the value given to
signal
is not one of the POSIX signals then an IllegalArgumentException
will be thrown.handler
- An AsyncEventHandler
which will be scheduled when the given signal occurs.public static void setHandler(int signal, AsyncEventHandler handler)
AsyncEventHandler
as the handler of the AsyncEvent
of the given signal.signal
- One of the POSIX signals from this (e.g., this.SIGLOST
). If the value given to
signal
is not one of the POSIX signals then an IllegalArgumentException
will be thrown.handler
- An AsyncEventHandler
which will be scheduled when the given signal occurs.
If h is null then no handler will be associated with this
(i.e., remove all handlers).
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |