* Get a map with all objects referenced by a peeled ref.
*
* @return a map with all objects referenced by a peeled ref.
+ * @throws IOException
*/
@NonNull
- public Map<AnyObjectId, Set<Ref>> getAllRefsByPeeledObjectId() {
- Map<String, Ref> allRefs = getAllRefs();
+ public Map<AnyObjectId, Set<Ref>> getAllRefsByPeeledObjectId()
+ throws IOException {
+ List<Ref> allRefs = getRefDatabase().getRefs();
Map<AnyObjectId, Set<Ref>> ret = new HashMap<>(allRefs.size());
- for (Ref ref : allRefs.values()) {
+ for (Ref ref : allRefs) {
ref = peel(ref);
AnyObjectId target = ref.getPeeledObjectId();
if (target == null)
return pc;
}
- private Ref[] getRefs(AnyObjectId commitId) {
+ private Ref[] getRefs(AnyObjectId commitId) throws IOException {
if (reverseRefMap == null) {
reverseRefMap = repository.getAllRefsByPeeledObjectId();
for (Map.Entry<AnyObjectId, Set<Ref>> entry : additionalRefMap