[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[jgit-dev] Exceptions thrown by GitCommand.call
- From: Kevin Sawicki <kevinsawicki@xxxxxxxxx>
- Date: Sun, 25 Sep 2011 11:18:29 -0700
- Delivered-to: email@example.com
Some subclasses of GitCommand have call() signatures that throw only GitApiException (CherryPick, Revert), some throw only JGitInternalException (AddNote, Blame, DeleteTag), and others throw a mix of exception types.
Going forward, is there a pattern that new commands should follow? Just mirror the signature of GitCommand and declare a throws of Exception only?
Looking at the documentation of GitApiException, it would seem that maybe that should be the exception class to throw consistently for newly added commands.
This is just a general question of what is the best practice that we may want to document and follow for consistency as new Git commands are added.