Class PriorityInheritance

  extended byjavax.realtime.MonitorControl
      extended byjavax.realtime.PriorityInheritance

public class PriorityInheritance
extends MonitorControl

Singleton class specifying use of the priority inheritance protocol. If a thread or schedulable object t1 attempts to enter code that is synchronized on an object obj governed by this protocol, and obj is currently locked by a lower-priority thread or schedulable object t2, then

  1. If t1's active priority does not exceed the maximum priority allowed by t2's scheduler, then t1 becomes a priority source for t2; t1 ceases to serve as a priority source for t2 when either t2 releases the lock on obj, or t1 ceases attempting to synchronize on obj (e.g., when t1 incurs an ATC).
  2. Otherwise (i.e., t1's active priority exceeds the maximum priority allowed by t2's scheduler), an IllegalThreadStateException is thrown in t1.

Note on the 2nd rule: throwing the exception in t1, rather than in t2, ensures that the exception is synchronous.

See also MonitorControl and PriorityCeilingEmulation

Method Summary
static PriorityInheritance instance()
          Return a reference to the singleton PriorityInheritance.
Methods inherited from class javax.realtime.MonitorControl
getMonitorControl, getMonitorControl, setMonitorControl, setMonitorControl
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Method Detail


public static PriorityInheritance instance()
Return a reference to the singleton PriorityInheritance.

This is the default MonitorControl policy in effect at system startup.

The PriorityInheritance instance shall be allocated in ImmortalMemory.