Module utilities

Class ThreadContext

java.lang.Object
de.grogra.util.ThreadContext

public final class ThreadContext extends Object
  • Field Details

  • Method Details

    • getId

      public int getId()
    • current

      public static ThreadContext current()
    • isCurrent

      public boolean isCurrent()
    • getThread

      public Thread getThread()
    • check

      public ThreadContext check()
    • registerProperty

      public static int registerProperty()
    • getProperty

      public Object getProperty(int propertyId)
    • setProperty

      public void setProperty(int propertyId, Object value)
    • checkInterruption

      public void checkInterruption() throws InterruptedException
      Throws:
      InterruptedException
    • join

      public void join()
    • leave

      public void leave()
    • joinWhileExecuting

      public void joinWhileExecuting(Runnable r)
    • hasHigherPriorityThan

      public boolean hasHigherPriorityThan(ThreadContext o)
    • getPriority

      public short getPriority()
    • setPriority

      public void setPriority(short priority)