Package wt.util

Class DebugProperties

java.lang.Object
wt.util.DebugProperties
All Implemented Interfaces:
Serializable

public class DebugProperties extends Object implements Serializable
This utility class provides access to all the properties that are used to configure information capture to aid in debugging. It gets initialized from the debug.properties file.

Supported API: true

Extendable: false
See Also:
  • Method Summary

    Modifier and Type
    Method
    Description
    static boolean
    getFlag(int flag, Object target)
    Determines if a particular flag is set, for a particular object.
    static boolean
    getFlag(int flag, Object target, String qualifier)
    Determines if a particular flag is set, for a particular object, qualified by the qualifier.
    static boolean
    isData(Object target)
    Determines if the DATA flag is set, for a particular object.
    static boolean
    isData(Object target, String qualifier)
    Determines if the DATA flag is set, for a particular object, qualified by the qualifier.
    static boolean
    isDebugOn(String target)
    Flag that specifies if any debug capture can take place for a specific target.
    static boolean
    Determines if the EXCEPTION flag is set, for a particular object.
    static boolean
    isException(Object target, String qualifier)
    Determines if the EXCEPTION flag is set, for a particular object, qualified by the qualifier.
    static boolean
    isReport(Object target)
    Determines if the REPORT flag is set, for a particular object.
    static boolean
    isReport(Object target, String qualifier)
    Determines if the REPORT flag is set, for a particular object, qualified by the qualifier.
    static boolean
    Determines if the STACK_TRACE flag is set, for a particular object.
    static boolean
    isStackTrace(Object target, String qualifier)
    Determines if the STACK_TRACE flag is set, for a particular object, qualified by the qualifier.
    static boolean
    isTrace(Object target)
    Determines if the TRACE flag is set, for a particular object.
    static boolean
    isTrace(Object target, String qualifier)
    Determines if the TRACE flag is set, for a particular object, qualified by the qualifier.
    static void
    setFlag(int flag, String target, DebugType target_type, String qualifier, boolean value)
    Sets the flag, for a particular target, which may be qualified by the qualifier.

    Methods inherited from class java.lang.Object

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

    • isDebugOn

      public static boolean isDebugOn(String target)
      Flag that specifies if any debug capture can take place for a specific target.

      Supported API: true
      Parameters:
      target -
      Returns:
      boolean
    • isData

      public static boolean isData(Object target)
      Determines if the DATA flag is set, for a particular object.

      Supported API: true
      Parameters:
      target - an object that is the target of the flag; the object can be an instance of a Class, or a Class, so that it can be used from instance methods or static methods
      Returns:
      true, if the flag is set, otherwise false.
      See Also:
    • isData

      public static boolean isData(Object target, String qualifier)
      Determines if the DATA flag is set, for a particular object, qualified by the qualifier.

      Supported API: true
      Parameters:
      target - an object that is the target of the flag; the object can be an instance of a Class, or a Class, so that it can be used from instance methods or static methods
      qualifier - a string that provides an open end qualification for the target
      Returns:
      true, if the flag is set, otherwise false.
      See Also:
    • isException

      public static boolean isException(Object target)
      Determines if the EXCEPTION flag is set, for a particular object.

      Supported API: true
      Parameters:
      target - an object that is the target of the flag; the object can be an instance of a Class, or a Class, so that it can be used from instance methods or static methods
      Returns:
      true, if the flag is set, otherwise false.
      See Also:
    • isException

      public static boolean isException(Object target, String qualifier)
      Determines if the EXCEPTION flag is set, for a particular object, qualified by the qualifier.

      Supported API: true
      Parameters:
      target - an object that is the target of the flag; the object can be an instance of a Class, or a Class, so that it can be used from instance methods or static methods
      qualifier - a string that provides an open end qualification for the target
      Returns:
      true, if the flag is set, otherwise false.
      See Also:
    • isReport

      public static boolean isReport(Object target)
      Determines if the REPORT flag is set, for a particular object.

      Supported API: true
      Parameters:
      target - an object that is the target of the flag; the object can be an instance of a Class, or a Class, so that it can be used from instance methods or static methods
      Returns:
      true, if the flag is set, otherwise false.
      See Also:
    • isReport

      public static boolean isReport(Object target, String qualifier)
      Determines if the REPORT flag is set, for a particular object, qualified by the qualifier.

      Supported API: true
      Parameters:
      target - an object that is the target of the flag; the object can be an instance of a Class, or a Class, so that it can be used from instance methods or static methods
      qualifier - a string that provides an open end qualification for the target
      Returns:
      true, if the flag is set, otherwise false.
      See Also:
    • isStackTrace

      public static boolean isStackTrace(Object target)
      Determines if the STACK_TRACE flag is set, for a particular object.

      Supported API: true
      Parameters:
      target - an object that is the target of the flag; the object can be an instance of a Class, or a Class, so that it can be used from instance methods or static methods
      Returns:
      true, if the flag is set, otherwise false.
      See Also:
    • isStackTrace

      public static boolean isStackTrace(Object target, String qualifier)
      Determines if the STACK_TRACE flag is set, for a particular object, qualified by the qualifier.

      Supported API: true
      Parameters:
      target - an object that is the target of the flag; the object can be an instance of a Class, or a Class, so that it can be used from instance methods or static methods
      qualifier - a string that provides an open end qualification for the target
      Returns:
      true, if the flag is set, otherwise false.
      See Also:
    • isTrace

      public static boolean isTrace(Object target)
      Determines if the TRACE flag is set, for a particular object.

      Supported API: true
      Parameters:
      target - an object that is the target of the flag; the object can be an instance of a Class, or a Class, so that it can be used from instance methods or static methods
      Returns:
      true, if the flag is set, otherwise false.
      See Also:
    • isTrace

      public static boolean isTrace(Object target, String qualifier)
      Determines if the TRACE flag is set, for a particular object, qualified by the qualifier.

      Supported API: true
      Parameters:
      target - an object that is the target of the flag; the object can be an instance of a Class, or a Class, so that it can be used from instance methods or static methods
      qualifier - a string that provides an open end qualification for the target
      Returns:
      true, if the flag is set, otherwise false.
      See Also:
    • getFlag

      public static boolean getFlag(int flag, Object target)
      Determines if a particular flag is set, for a particular object.
       Determination is made based on the following algorithm for finding
       a flag configuration that best matches the target:
       

      1) classname/target.toString()/current thread 2) classname/target.toString() 3) classname/current thread 4) classname



      Supported API: true
      Parameters:
      flag - the flag to be checked
      target - an object that is the target of the flag; the object can be an instance of a Class, or a Class, so that it can be used from instance methods or static methods
      Returns:
      true, if the flag is set, otherwise false.
      See Also:
    • getFlag

      public static boolean getFlag(int flag, Object target, String qualifier)
      Determines if a particular flag is set, for a particular object, qualified by the qualifier.
       Determination is made based on the following algorithm for finding
       a flag configuration that best matches the target:
       

      1) classname/target.toString()/current thread 2) classname/target.toString() 3) classname/qualifier 4) classname/current thread 5) classname



      Supported API: true
      Parameters:
      flag - the flag to be checked
      target - an object that is the target of the flag; the object can be an instance of a Class, or a Class, so that it can be used from instance methods or static methods
      qualifier - a string that provides an open end qualification for the target
      Returns:
      true, if the flag is set, otherwise false.
      See Also:
    • setFlag

      public static void setFlag(int flag, String target, DebugType target_type, String qualifier, boolean value)
      Sets the flag, for a particular target, which may be qualified by the qualifier.

      Supported API: true
      Parameters:
      flag - the flag to be checked
      target - a String that is the key for a target. If target is a Class, it is the classname. If target is an instance of a Class, it is the classname +"/"+ instance.toString(). If target is a package, it is the package name. If target is a defined group, it is the name of the group.
      target_type - one of the predefined DebugTypes
      qualifier - a string that provides an open end qualification for the target
      value - true, if the flag is to be be set; false if the flag is to be cleared
      See Also: