public class NoHeapRealtimeThread extends RealtimeThread
Threads of this class are guaranteed never to be interrupted by garbage collector activity as long as they run at a priority higher than any RealtimeThread or normal java Thread.
Within JamaicaVM, the use of NoHeapRealtimeThreads is not required since even normal threads are not interrupted by garbage collector activity.
When used with JamaicaVM, even NoHeapRealtimeThreads are permitted to access all objects that were allocated in the garbage collected HeapMemory.
Thread.State, Thread.UncaughtExceptionHandler
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY
Constructor and Description |
---|
NoHeapRealtimeThread(SchedulingParameters scheduling,
MemoryArea area)
Constructor to create a NoHeapRealtimeThread with the given
scheduling parameters and memory area.
|
NoHeapRealtimeThread(SchedulingParameters scheduling,
ReleaseParameters release,
MemoryArea area)
Constructor to create a NoHeapRealtimeThread with the given
scheduling and release parameters and memory area.
|
NoHeapRealtimeThread(SchedulingParameters scheduling,
ReleaseParameters release,
MemoryParameters memory,
MemoryArea area,
ProcessingGroupParameters group,
Runnable logic)
Constructor to create a NoHeapRealtimeThread using specified
scheduling, release, and memory parameters, using the specified
memory area, group, and logic.
|
Modifier and Type | Method and Description |
---|---|
void |
start()
start starts this NoHeapRealtimeThread.
|
addIfFeasible, addToFeasibility, currentRealtimeThread, deschedulePeriodic, fire, getCurrentMemoryArea, getDispatcher, getInitialMemoryAreaIndex, getMemoryArea, getMemoryAreaStackDepth, getMemoryParameters, getOuterMemoryArea, getProcessingGroupParameters, getReleaseParameters, getScheduler, getSchedulingParameters, interrupt, release, removeFromFeasibility, run, schedulePeriodic, setIfFeasible, setIfFeasible, setIfFeasible, setIfFeasible, setIfFeasible, setMemoryParameters, setMemoryParametersIfFeasible, setProcessingGroupParameters, setProcessingGroupParametersIfFeasible, setReleaseParameters, setReleaseParametersIfFeasible, setScheduler, setScheduler, setSchedulingParameters, setSchedulingParametersIfFeasible, sleep, sleep, startPeriodic, waitForNextPeriod, waitForNextPeriodInterruptible, waitForNextRelease, waitForNextReleaseInterruptible
activeCount, checkAccess, clone, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, stop, stop, suspend, toString, yield
public NoHeapRealtimeThread(SchedulingParameters scheduling, MemoryArea area) throws IllegalArgumentException
IllegalArgumentException
- iff scheduling is not compatible
with the default scheduler, i.e., iff it is non-null and not
an instance of PriorityParameters.IllegalArgumentException
- if area is not ScopedMemory or
ImmortalMemory.IllegalAssignmentError
- if scheduling or area reside in
memory areas whose objects cannot be referred to by this or this
object resides in a memory area that cannot be referenced by
scheduling.scheduling
- the scheduling parameters to be used for the
new NoHeapRealtimeThread. This can be shared with several
Schedulable objects. If it is null, a copy of the creator's value
will be created in the same memory area as this RealtimeThread
object. If it is null and the current thread is a normal Java
thread, the scheduling parameters will be set to the default
priority.area
- the memory area to be used for the new
NoHeapRealtimeThread. area must not be null nor HeapMemory.public NoHeapRealtimeThread(SchedulingParameters scheduling, ReleaseParameters release, MemoryArea area) throws IllegalArgumentException
IllegalArgumentException
- iff scheduling or release
parameters are not compatible with the default scheduler, i.e.,
iff they are non-null and not an instance of PriorityParameters
or PeriodicParameters, AperidodicParameters and
SporadicParameters, respectively.IllegalArgumentException
- if area is not ScopedMemory or
ImmortalMemory.IllegalAssignmentError
- if scheduling, release, or area
reside in memory areas whose objects cannot be referred to by this
or this object resides in a memory area that cannot be referenced
by scheduling or release.scheduling
- the scheduling parameters to be used for the
new NoHeapRealtimeThread. This can be shared with several
Schedulable objects. If it is null, a copy of the creator's value
will be created in the same memory area as this RealtimeThread
object. If it is null and the current thread is a normal Java
thread, the scheduling parameters will be set to the default
priority.release
- ReleaseParameters to be associated with the new
thread. This can be shared with several Schedulable objects. If
it is null, default release parameters will be used.
area
- the memory area to be used for the new
NoHeapRealtimeThread. area must neither be null nor HeapMemory.public NoHeapRealtimeThread(SchedulingParameters scheduling, ReleaseParameters release, MemoryParameters memory, MemoryArea area, ProcessingGroupParameters group, Runnable logic) throws IllegalArgumentException
If group is null, the thread group is inherited from the + * creating thread unless this RealtimeThread object resides in ScopedMemory. In this case, the thread group will be set to null.
IllegalArgumentException
- iff scheduling or release
parameters are not compatible with the default scheduler, i.e.,
iff they are non-null and not an instance of PriorityParameters
or PeriodicParameters, AperidodicParameters and
SporadicParameters, respectively.IllegalAssignmentError
- if scheduling, release, memory,
area, group, or logic reside in memory areas whose objects cannot
be referred to by this or this object resides in a memory area that
cannot be referenced by scheduling, release, or memory.scheduling
- the scheduling parameters to be used for the
new NoHeapRealtimeThread. This can be shared with several
Schedulable objects. If it is null, a copy of the creator's value
will be created in the same memory area as this RealtimeThread
object. If it is null and the current thread is a normal Java
thread, the scheduling parameters will be set to the default
priority.release
- ReleaseParameters to be associated with the new
thread. This can be shared with several Schedulable objects. If
it is null, default release parameters will be used.
memory
- MemoryParameters to be associated with the new
thread. May be null for unrestricted amount and rate of memory
allocation for the new thread.area
- the memory area to be used for the new
NoHeapRealtimeThread. area must neither be null nor HeapMemory.group
- ProcessingGroupParameters to be associated with
this. This can be shared with several Schedulable objects. If it
is null, this will not be associated with any processing group.logic
- Runnable to be used as the logic for this. If it is
null, the run() method in this new RealtimeThread object will be
called when the thread is started.public void start()
start
in class RealtimeThread
MemoryAccessError
- if this object, its logic, scheduling
parameters, release parameters, memory parameters, processing
group, or scheduler do not reside in heap memory.Thread.run()
,
Thread.stop()
aicas GmbH, Karlsruhe, Germany —www.aicas.com
Copyright © 2001-2019 aicas GmbH. All Rights Reserved.