Class ExceptionHandler<S extends Solution<S,I>,I extends Instance>

java.lang.Object
es.urjc.etsii.grafo.exception.ExceptionHandler<S,I>
Type Parameters:
S - Solution class
I - Instance class
Direct Known Subclasses:
DefaultExceptionHandler

public abstract class ExceptionHandler<S extends Solution<S,I>,I extends Instance> extends Object
Abstract class to provide behaviour when an uncontrolled exception reaches executor code.
  • Constructor Details

    • ExceptionHandler

      public ExceptionHandler()
  • Method Details

    • handleException

      public abstract void handleException(String experimentName, int iteration, Exception e, Optional<S> s, I i, Algorithm<S,I> algorithm)
      What should be done when there is an unhandled exception in the user algorithm implementation?
      Parameters:
      experimentName - Experiment name
      iteration - Iteration if known, -1 if not
      e - Thrown exception
      s - Current solution, if available
      i - Current instance
      algorithm - Current algorithm
    • toString

      public String toString()
      Overrides:
      toString in class Object