org.eclipse.jgit.errors
Class AmbiguousObjectException

java.lang.Object
  extended by java.lang.Throwable
      extended by java.lang.Exception
          extended by java.io.IOException
              extended by org.eclipse.jgit.errors.AmbiguousObjectException
All Implemented Interfaces:
Serializable

public class AmbiguousObjectException
extends IOException

An AbbreviatedObjectId cannot be extended.

See Also:
Serialized Form

Constructor Summary
AmbiguousObjectException(AbbreviatedObjectId id, Collection<ObjectId> candidates)
          Construct a MissingObjectException for the specified object id.
 
Method Summary
 AbbreviatedObjectId getAbbreviatedObjectId()
           
 Collection<ObjectId> getCandidates()
           
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, 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

AmbiguousObjectException

public AmbiguousObjectException(AbbreviatedObjectId id,
                                Collection<ObjectId> candidates)
Construct a MissingObjectException for the specified object id. Expected type is reported to simplify tracking down the problem.

Parameters:
id - SHA-1
candidates - the candidate matches returned by the ObjectReader.
Method Detail

getAbbreviatedObjectId

public AbbreviatedObjectId getAbbreviatedObjectId()
Returns:
the AbbreviatedObjectId that has more than one result.

getCandidates

public Collection<ObjectId> getCandidates()
Returns:
the matching candidates (or at least a subset of them).


Copyright © 2013. All Rights Reserved.