Reset() public method

public Reset ( ) : void
return void
示例#1
0
        public void Reset()
        {
            var idx = new ArrayIndex(new int[] { 1, 2, 3, 4, 5 });

            idx.Increment(3);
            Assert.IsTrue(idx.Index.SequenceEqual(new int[] { 3 }));

            idx.Reset();
            Assert.IsTrue(idx.Index.SequenceEqual(new int[] { 0 }));
        }
        public void Reset()
        {
            var idx = new ArrayIndex(new int[] { 1, 2, 3, 4, 5 });

            idx.Increment(3);
            Assert.IsTrue(idx.Index.SequenceEqual(new int[] { 3 }));

            idx.Reset();
            Assert.IsTrue(idx.Index.SequenceEqual(new int[] { 0 }));
        }