Class MismatchingChecksumException

java.lang.Object
java.lang.Throwable
java.lang.Exception
java.io.IOException
de.xima.fc.exceptions.MismatchingChecksumException
All Implemented Interfaces:
Serializable

public class MismatchingChecksumException extends IOException
A special IOException thrown when the actual checksum (e.g. MD5, SHA256 etc.) of a piece of data did not match the expected checksum.
Since:
8.0.0
Author:
XIMA MEDIA GmbH
See Also:
  • Constructor Details

    • MismatchingChecksumException

      public MismatchingChecksumException(String checksumType, String actualChecksum, String expectedChecksum)
      Creates a new exception for when an actual checksum did not match the expected checksum.
      Parameters:
      checksumType - Type of the checksum, e.g. MD5 or SHA256.
      actualChecksum - Actual checksum of the piece of data.
      expectedChecksum - Expected checksum.
    • MismatchingChecksumException

      public MismatchingChecksumException(String checksumType, String actualChecksum, String expectedChecksum, String message)
      Creates a new exception for when an actual checksum did not match the expected checksum.
      Parameters:
      checksumType - Type of the checksum, e.g. MD5 or SHA256.
      actualChecksum - Actual checksum of the piece of data.
      expectedChecksum - Expected checksum.
      message - Message with details about the checksum mismatch.
    • MismatchingChecksumException

      public MismatchingChecksumException(String checksumType, String actualChecksum, String expectedChecksum, String message, Throwable cause)
      Creates a new exception for when an actual checksum did not match the expected checksum.
      Parameters:
      checksumType - Type of the checksum, e.g. MD5 or SHA256.
      actualChecksum - Actual checksum of the piece of data.
      expectedChecksum - Expected checksum.
      message - Message with details about the checksum mismatch.
      cause - Underlying cause of the error.
    • MismatchingChecksumException

      public MismatchingChecksumException(String checksumType, String actualChecksum, String expectedChecksum, Throwable cause)
      Creates a new exception for when an actual checksum did not match the expected checksum.
      Parameters:
      checksumType - Type of the checksum, e.g. MD5 or SHA256.
      actualChecksum - Actual checksum of the piece of data.
      expectedChecksum - Expected checksum.
      cause - Underlying cause of the error.
  • Method Details

    • getActualChecksum

      public String getActualChecksum()
      Returns:
      Actual checksum of the piece of data.
    • getChecksumType

      public String getChecksumType()
      Returns:
      Type of the checksum, e.g. MD5 or SHA256.
    • getExpectedChecksum

      public String getExpectedChecksum()
      Returns:
      Expected checksum for the piece of data.