Enum Class DebugLevel

java.lang.Object
java.lang.Enum<DebugLevel>
org.ddolib.util.debug.DebugLevel
All Implemented Interfaces:
Serializable, Comparable<DebugLevel>, Constable

public enum DebugLevel extends Enum<DebugLevel>
Defines the different levels of debugging information and validation that can be enabled during the execution of the solver.

The DebugLevel controls how strictly the framework validates internal consistency, model correctness, and debugging artifacts generated during search. Higher levels include all checks from lower levels, plus additional diagnostics and export tools.

This configuration is typically set through the model definition (see Model.debugMode()), allowing users to choose between performance-oriented runs and detailed debugging sessions.

  • Enum Constant Details

    • OFF

      public static final DebugLevel OFF
      Disables all debugging features.

      This mode is intended for production runs or benchmarking, where performance is prioritized and no additional checks or debug information are generated.

    • ON

      public static final DebugLevel ON
      Enables basic debugging checks.

      This mode verifies fundamental properties of the model components, such as:

      • Equality and correctness of state representations.
      • Proper definition and consistency of lower bounds.
      These checks help detect common modeling or implementation errors early in the solving process.
    • EXTENDED

      public static final DebugLevel EXTENDED
      Enables extended debugging and diagnostic tools.

      Includes all checks from ON, and adds:

      • Export of failing or inconsistent decision diagrams (as .dot files) to assist with visualization and analysis.
      • Additional consistency verification of lower-bound computations (particularly useful for A*-based algorithms).
      This mode is recommended when investigating unexpected solver behavior or validating complex model implementations.
  • Method Details

    • values

      public static DebugLevel[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static DebugLevel valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null