Class CorruptObjectException

  • All Implemented Interfaces:
    java.io.Serializable

    public class CorruptObjectException
    extends java.io.IOException
    Exception thrown when an object cannot be read from Git.
    See Also:
    Serialized Form
    • Constructor Summary

      Constructors 
      Constructor Description
      CorruptObjectException​(java.lang.String why)
      Construct a CorruptObjectException for reporting a problem not associated with a specific object id.
      CorruptObjectException​(java.lang.String why, java.lang.Throwable cause)
      Construct a CorruptObjectException for reporting a problem not associated with a specific object id.
      CorruptObjectException​(AnyObjectId id, java.lang.String why)
      Construct a CorruptObjectException for reporting a problem specified object id
      CorruptObjectException​(ObjectChecker.ErrorType type, AnyObjectId id, java.lang.String why)
      Report a specific error condition discovered in an object.
      CorruptObjectException​(ObjectId id, java.lang.String why)
      Construct a CorruptObjectException for reporting a problem specified object id
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      ObjectChecker.ErrorType getErrorType()
      Specific error condition identified by ObjectChecker.
      • Methods inherited from class java.lang.Throwable

        addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • CorruptObjectException

        public CorruptObjectException​(ObjectChecker.ErrorType type,
                                      AnyObjectId id,
                                      java.lang.String why)
        Report a specific error condition discovered in an object.
        Parameters:
        type - type of error
        id - identity of the bad object
        why - description of the error.
        Since:
        4.2
      • CorruptObjectException

        public CorruptObjectException​(AnyObjectId id,
                                      java.lang.String why)
        Construct a CorruptObjectException for reporting a problem specified object id
        Parameters:
        id - a AnyObjectId
        why - error message
      • CorruptObjectException

        public CorruptObjectException​(ObjectId id,
                                      java.lang.String why)
        Construct a CorruptObjectException for reporting a problem specified object id
        Parameters:
        id - a ObjectId
        why - error message
      • CorruptObjectException

        public CorruptObjectException​(java.lang.String why)
        Construct a CorruptObjectException for reporting a problem not associated with a specific object id.
        Parameters:
        why - error message
      • CorruptObjectException

        public CorruptObjectException​(java.lang.String why,
                                      java.lang.Throwable cause)
        Construct a CorruptObjectException for reporting a problem not associated with a specific object id.
        Parameters:
        why - message describing the corruption.
        cause - optional root cause exception
        Since:
        3.4