private DirCacheTree parent;
/** Name of this tree within its parent. */
- private byte[] encodedName;
+ byte[] encodedName;
/** Number of {@link DirCacheEntry} records that belong to this tree. */
private int entrySpan;
* The low {@link #bits} of the SHA-1 are used to select the segment from
* this directory. Each segment is constant sized at 2^SEGMENT_BITS.
*/
- private V[][] directory;
+ V[][] directory;
/** Total number of objects in this map. */
- private int size;
+ int size;
/** The map doubles in capacity when {@link #size} reaches this target. */
private int grow;
/** Number of low bits used to form the index into {@link #directory}. */
- private int bits;
+ int bits;
/** Low bit mask to index into {@link #directory}, {@code 2^bits-1}. */
private int mask;
public class ObjectIdSubclassMap<V extends ObjectId> implements Iterable<V> {
private static final int INITIAL_TABLE_SIZE = 2048;
- private int size;
+ int size;
private int grow;
private int mask;
- private V[] table;
+ V[] table;
/** Create an empty map. */
public ObjectIdSubclassMap() {
private static final int BLOCK_MASK = BLOCK_SIZE - 1;
- private T[][] directory;
+ T[][] directory;
- private int size;
+ int size;
private int tailDirIdx;
return new MyIterator();
}
- private static final int toDirectoryIndex(int index) {
+ static final int toDirectoryIndex(int index) {
return index >>> BLOCK_BITS;
}
- private static final int toBlockIndex(int index) {
+ static final int toBlockIndex(int index) {
return index & BLOCK_MASK;
}
}
}
- private final static Logger LOG = LoggerFactory.getLogger(FS.class);
+ final static Logger LOG = LoggerFactory.getLogger(FS.class);
/** The auto-detected implementation selected for this operating system and JRE. */
public static final FS DETECTED = detect();
private final String desc;
private final String dir;
private final boolean debug = LOG.isDebugEnabled();
- private final AtomicBoolean fail = new AtomicBoolean();
+ final AtomicBoolean fail = new AtomicBoolean();
- private GobblerThread(Process p, String[] command, File dir) {
+ GobblerThread(Process p, String[] command, File dir) {
this.p = p;
if (debug) {
this.desc = Arrays.asList(command).toString();
return (RefList<T>) EMPTY;
}
- private final Ref[] list;
+ final Ref[] list;
- private final int cnt;
+ final int cnt;
RefList(Ref[] list, int cnt) {
this.list = list;
* All reference names in this map must start with this prefix. If the
* prefix is not the empty string, it must end with a '/'.
*/
- private final String prefix;
+ final String prefix;
/** Immutable collection of the packed references at construction time. */
- private RefList<Ref> packed;
+ RefList<Ref> packed;
/**
* Immutable collection of the loose references at construction time.
* are typically unresolved, so they only tell us who their target is, but
* not the current value of the target.
*/
- private RefList<Ref> loose;
+ RefList<Ref> loose;
/**
* Immutable collection of resolved symbolic references.
* from {@link #loose}. Every entry in this list must be matched by an entry
* in {@code loose}, otherwise it might be omitted by the map.
*/
- private RefList<Ref> resolved;
+ RefList<Ref> resolved;
- private int size;
+ int size;
- private boolean sizeIsValid;
+ boolean sizeIsValid;
private Set<Entry<String, Ref>> entrySet;
return name;
}
- private String toMapKey(Ref ref) {
+ String toMapKey(Ref ref) {
String name = ref.getName();
if (0 < prefix.length())
name = name.substring(prefix.length());
protected static final int DEFAULT_IN_CORE_LIMIT = 1024 * 1024;
/** Chain of data, if we are still completely in-core; otherwise null. */
- private ArrayList<Block> blocks;
+ ArrayList<Block> blocks;
/**
* Maximum number of bytes we will permit storing in memory.