Class DokimosTypeConversionException

java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
dev.dokimos.core.exceptions.DokimosTypeConversionException
All Implemented Interfaces:
Serializable

public class DokimosTypeConversionException extends RuntimeException
Thrown when a stored output value cannot be converted to the requested type by one of the typed read accessors (for example EvalTestCase.actualOutputAs(Class) or Example.expectedOutputAs(dev.dokimos.core.OutputType)).

This is an unchecked exception: a conversion failure is a programming/data error (the requested type does not match the shape of the stored value), not a recoverable condition callers are expected to handle on every call. The evaluation path catches it and scores the affected item as failed rather than aborting the whole run.

The underlying cause (a Jackson conversion error) is attached via Throwable.getCause() for diagnostics, typed as Throwable.

See Also:
  • Constructor Details

    • DokimosTypeConversionException

      public DokimosTypeConversionException(String message)
      Creates an exception with the given detail message.
      Parameters:
      message - a human-readable description of the conversion failure
    • DokimosTypeConversionException

      public DokimosTypeConversionException(String message, Throwable cause)
      Creates an exception with the given detail message and underlying cause.
      Parameters:
      message - a human-readable description of the conversion failure
      cause - the underlying error that triggered the failure (for example a Jackson conversion error), typed as Throwable