Class MalformedFileException

All Implemented Interfaces:
QuantFinException, Serializable

public class MalformedFileException extends IOException implements QuantFinException
A file or saved state that this library cannot read because its contents are wrong, not because the read failed: a bad magic number, an unknown format version, a duplicate checkpoint section, a journal that is not a FIX journal.

Extends IOException, which these sites threw before 2.2, so existing catch (IOException e) handlers still catch it. A genuine read failure (disk error, closed stream) stays a plain IOException; test e instanceof QuantFinException to tell the two apart.

Since:
2.2
See Also:
  • Constructor Details

    • MalformedFileException

      public MalformedFileException(String message)
      Creates the exception.
      Parameters:
      message - what was wrong with the file
    • MalformedFileException

      public MalformedFileException(String message, Throwable cause)
      Creates the exception with the underlying cause.
      Parameters:
      message - what was wrong with the file
      cause - the lower-level failure, for example an EOFException