Class BasicThreadInformation

  • All Implemented Interfaces:
    ThreadInformation

    class BasicThreadInformation
    extends java.lang.Object
    implements ThreadInformation
    Generates information about the current Thread. Used internally by ThreadDumpMessage.
    • Constructor Summary

      Constructors 
      Constructor Description
      BasicThreadInformation​(java.lang.Thread thread)
      The Constructor.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean equals​(java.lang.Object o)  
      int hashCode()  
      void printStack​(java.lang.StringBuilder sb, java.lang.StackTraceElement[] trace)
      Format the StackTraceElements.
      void printThreadInfo​(java.lang.StringBuilder sb)
      Print the thread information.
      • Methods inherited from class java.lang.Object

        clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • id

        private final long id
      • name

        private final java.lang.String name
      • longName

        private final java.lang.String longName
      • state

        private final java.lang.Thread.State state
      • priority

        private final int priority
      • isAlive

        private final boolean isAlive
      • isDaemon

        private final boolean isDaemon
      • threadGroupName

        private final java.lang.String threadGroupName
    • Constructor Detail

      • BasicThreadInformation

        BasicThreadInformation​(java.lang.Thread thread)
        The Constructor.
        Parameters:
        thread - The Thread to capture.
    • Method Detail

      • equals

        public boolean equals​(java.lang.Object o)
        Overrides:
        equals in class java.lang.Object
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • printThreadInfo

        public void printThreadInfo​(java.lang.StringBuilder sb)
        Print the thread information.
        Specified by:
        printThreadInfo in interface ThreadInformation
        Parameters:
        sb - The StringBuilder.
      • printStack

        public void printStack​(java.lang.StringBuilder sb,
                               java.lang.StackTraceElement[] trace)
        Format the StackTraceElements.
        Specified by:
        printStack in interface ThreadInformation
        Parameters:
        sb - The StringBuilder.
        trace - The stack trace element array to format.