public void StructUseCustomEqualsWithoutBoxingSetup()
        {
            var r      = new Random();
            var points = new List <Point2DCustomEquals>();

            for (int i = 0; i < ItemsCount; i++)
            {
                points.Add(new Point2DCustomEquals(r.Next(RangeStart, RangeEnd), r.Next(RangeStart, RangeEnd)));
            }
            points.Add(new Point2DCustomEquals(ItemForSearch, ItemForSearch));
            manager = new Point2DManager <Point2DCustomEquals>(points);
        }
コード例 #2
0
        public void Setup()
        {
            var r      = new Random();
            var points = new List <Point2D>();

            for (int i = 0; i < ItemsCount; i++)
            {
                points.Add(new Point2D(r.Next(RangeStart, RangeEnd), r.Next(RangeStart, RangeEnd)));
            }
            points.Add(new Point2D(ItemForSearch, ItemForSearch));
            manager = new Point2DManager <Point2D>(points);
        }