Lawo.ComponentModel.PropertyChangedTest.IncrementAddends C# (CSharp) Méthode

IncrementAddends() private méthode

private IncrementAddends ( int index ) : int
index int
Résultat int
        private int IncrementAddends(int index, params Addend[] addends)
        {
            var totalCount = 0;

            if (index < addends.Length)
            {
                // The min value for count must be 2 so that there is a guarantee that AddedValue is changed for every loop
                // revolution.
                var count = this.Random.Next(2, 5);

                for (var value = 1; value <= count; ++value)
                {
                    addends[index].AddendValue = value;
                    totalCount += this.IncrementAddends(index + 1, addends) + 1;
                }
            }

            return totalCount;
        }