public class SignalDispatcher extends ActiveEventDispatcher<SignalDispatcher,Signal>
Signal
s.
An application can provide its own dispatcher, providing the priority for
the internal dispatching thread. This dispatching thread calls
process()
each time the signal is triggered.Constructor and Description |
---|
SignalDispatcher(SchedulingParameters scheduling)
Creates a new dispatcher, whose dispatching thread runs with the given
SchedulingParameters . |
SignalDispatcher(SchedulingParameters scheduling,
RealtimeThreadGroup group)
Creates a new dispatcher, whose dispatching thread runs with the given
SchedulingParameters . |
Modifier and Type | Method and Description |
---|---|
void |
deregister(Signal signal)
Deregisters the POSIX Signal from this dispatcher.
|
void |
destroy()
Releases all reasources thereby making the dispatcher unusable.
|
void |
register(Signal signal)
Registers a POSIX signal with this dispatcher.
|
static void |
setDefaultDispatcher(SignalDispatcher dispatcher)
Sets the system default signal dispatcher.
|
getRealtimeThreadGroup, getScheduler, getSchedulingParameters, setScheduler, setScheduler, setSchedulingParameters
public SignalDispatcher(SchedulingParameters scheduling, RealtimeThreadGroup group)
SchedulingParameters
.UnsupportedOperationException
- everytime, since this is not implemented yet.scheduling
- Parameters for scheduling this dispatcher.group
- Container for this dispatcher.public SignalDispatcher(SchedulingParameters scheduling)
SchedulingParameters
.UnsupportedOperationException
- everytime, since this is not implemented yet.scheduling
- For scheduling this dispatcher.public static void setDefaultDispatcher(SignalDispatcher dispatcher)
UnsupportedOperationException
- everytime, since this is not implemented yet.dispatcher
- An instance to be used when no dispatcher is
provided. When null
, the signal dispatcher is set
to the original system default.public void register(Signal signal) throws RegistrationException, StaticIllegalStateException, StaticIllegalArgumentException
register
in class ActiveEventDispatcher<SignalDispatcher,Signal>
RegistrationException
- when Signal
is already registered.StaticIllegalStateException
- when this
object has been destroyed.StaticIllegalArgumentException
- when
Signal
is not stopped.UnsupportedOperationException
- everytime, since this is not implemented yet.signal
- The signal instance to register.public void deregister(Signal signal) throws DeregistrationException, StaticIllegalStateException, StaticIllegalArgumentException
deregister
in class ActiveEventDispatcher<SignalDispatcher,Signal>
DeregistrationException
- when Signal
is not already
registered.StaticIllegalStateException
- when this
object has been destroyed.StaticIllegalArgumentException
- when
Signal
is not stopped.UnsupportedOperationException
- everytime, since this is not implemented yet.signal
- The signal instance to deregister.public void destroy() throws StaticIllegalStateException
destroy
in class ActiveEventDispatcher<SignalDispatcher,Signal>
StaticIllegalStateException
- when called on
a dispatcher that has one or more registered Signal
objects.UnsupportedOperationException
- everytime, since this is not implemented yet.aicas GmbH, Karlsruhe, Germany —www.aicas.com
Copyright © 2001-2019 aicas GmbH. All Rights Reserved.