private static class MethodCountCheck.MethodCounter
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
private java.util.Map<Scope,java.lang.Integer> |
counts
Maintains the counts.
|
private boolean |
inInterface
Indicated is an interface, in which case all methods are public.
|
private int |
total
Tracks the total.
|
Constructor and Description |
---|
MethodCounter(boolean inInterface)
Creates an interface.
|
Modifier and Type | Method and Description |
---|---|
private int |
getTotal()
Fetches total number of methods.
|
private void |
increment(Scope scope)
Increments to counter by one for the supplied scope.
|
private int |
value(Scope scope)
Gets the value of a scope counter.
|
private final java.util.Map<Scope,java.lang.Integer> counts
private final boolean inInterface
private int total
MethodCounter(boolean inInterface)
inInterface
- indicated if counter for an interface. In which
case, add all counts as public methods.private void increment(Scope scope)
scope
- the scope counter to increment.private int value(Scope scope)
scope
- the scope counter to get the value ofprivate int getTotal()