internal void EstablishInternalTackingValues(int lengthToCover)
{
ResetMaxValue(0);
ResetMinNonZeroValue(long.MaxValue);
int maxIndex = -1;
int minNonZeroIndex = -1;
long observedTotalCount = 0;
for (int index = 0; index < lengthToCover; index++)
{
long countAtIndex;
if ((countAtIndex = GetCountAtIndex(index)) > 0)
{
observedTotalCount += countAtIndex;
maxIndex = index;
if ((minNonZeroIndex == -1) && (index != 0))
{
minNonZeroIndex = index;
}
}
}
if (maxIndex >= 0)
{
UpdatedMaxValue(this.HighestEquivalentValue(ValueFromIndex(maxIndex)));
}
if (minNonZeroIndex >= 0)
{
UpdateMinNonZeroValue(ValueFromIndex(minNonZeroIndex));
}
TotalCount = observedTotalCount;
}