Browse Source

InMemoryRepository: Make inner class MemObjDatabase static

FindBugs reports:

  This class is an inner class, but does not use its embedded reference
  to the object which created it. This reference makes the instances
  of the class larger, and may keep the reference to the creator object
  alive longer than necessary. If possible, the class should be made
  static.

Change-Id: I9f49de32b4cd81b7ef1239b390353689263bf66e
Signed-off-by: David Pursehouse <david.pursehouse@gmail.com>
stable-4.9
David Pursehouse 7 years ago
parent
commit
c40e150790
  1. 2
      org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/InMemoryRepository.java

2
org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/InMemoryRepository.java

@ -107,7 +107,7 @@ public class InMemoryRepository extends DfsRepository {
} }
/** DfsObjDatabase used by InMemoryRepository. */ /** DfsObjDatabase used by InMemoryRepository. */
public class MemObjDatabase extends DfsObjDatabase { public static class MemObjDatabase extends DfsObjDatabase {
private List<DfsPackDescription> packs = new ArrayList<>(); private List<DfsPackDescription> packs = new ArrayList<>();
private int blockSize; private int blockSize;

Loading…
Cancel
Save