|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.lang.Thread
javax.realtime.RealtimeThread
javax.realtime.test.preemption.Job
Models jobs contending for a CPU accessed as a
Resource
. The actual CPU instance will be of concrete type
PriorityInheritanceResource
,
PreemptableResource
, or
PriorityCeilingResource
.
Field Summary | |
protected Resource |
cpu
The resource representing the CPU |
Fields inherited from class javax.realtime.RealtimeThread |
activePhaseToDo, currentEventNotice, currentPriority, defaultPriority, endTime, lastPriorityChangeNanos, lastWaitStart, logic, memoryArea, memoryParameters, processingGroup, releaseParameters, resourcesHeld, scheduler, scheduling, startAbsoluteMillis, started, startTime, terminated, timeWeightedPriority, waitingForResource, waitTime |
Fields inherited from class java.lang.Thread |
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY |
Constructor Summary | |
Job(java.lang.String name,
int priority,
Resource cpu,
int cycles,
RelativeTime pauseTime,
RelativeTime computationTime)
Constructor |
Method Summary | |
void |
body()
The behavior specification for this Job |
Methods inherited from class java.lang.Thread |
activeCount, checkAccess, countStackFrames, currentThread, destroy, dumpStack, enumerate, getContextClassLoader, getName, getPriority, getThreadGroup, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setName, setPriority, sleep, sleep, start, stop, stop, suspend, yield |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
protected Resource cpu
Constructor Detail |
public Job(java.lang.String name, int priority, Resource cpu, int cycles, RelativeTime pauseTime, RelativeTime computationTime)
name
- The name of this Job
priority
- The priority of this Job
cpu
- The PreemptableCPU
used by this Job
cycles
- The number of compute cycles of this Job
pauseTime
- The time to pause (hold) between compute cyclescomputationTime
- The time taken by each compute cycleMethod Detail |
public void body() throws java.lang.InterruptedException, ThreadTerminatedException
Job
body
in class RealtimeThread
java.lang.InterruptedException
- thrown if a wait()
is
interrupted
ThreadTerminatedException
- thrown if a simulation shutdown occurs
while this thread has not yet terminated
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |