Class DebugUtil


  • public class DebugUtil
    extends java.lang.Object
    This class contains several convenience methods mainly for debugging purposes.
    Restriction:
    This interface is not intended to be extended by clients.
    Restriction:
    This class is not intended to be instantiated by clients.
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static void printMethodTrace()
      Prints a trace message to stdout that gives info about the method that calls this method.
      static void printMethodTrace​(java.lang.String extraMessage)
      Prints a trace message to stdout that gives info about the method that calls this method.
      static void printObjectProperties​(java.lang.Object obj)
      Prints the values of javabean properties to the console.
      static java.lang.String safeClassName​(java.lang.Object obj)  
      static java.lang.String toStringWithClass​(java.lang.Object obj)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • printMethodTrace

        public static void printMethodTrace()
        Prints a trace message to stdout that gives info about the method that calls this method.
      • printMethodTrace

        public static void printMethodTrace​(java.lang.String extraMessage)
        Prints a trace message to stdout that gives info about the method that calls this method. The output is in a format that will show up as a hyperlink in the eclipse console.
      • safeClassName

        public static java.lang.String safeClassName​(java.lang.Object obj)
      • toStringWithClass

        public static java.lang.String toStringWithClass​(java.lang.Object obj)
      • printObjectProperties

        public static void printObjectProperties​(java.lang.Object obj)
        Prints the values of javabean properties to the console. This method is not recursive, it does not print nested properties. Example of usage: IResource resource = ...; DebugUtil.printObjectProperties(resource); DebugUtil.printObjectProperties(resource.getResourceAttributes());
        Since:
        5.1