예제 #1
0
        public void MaxInt32()
        {
            Aggregate <int, int>("int:empty", Enumerable.Max, x => EnumerableExt.Max(x, Comparer <int> .Default));
            Aggregate <int?, int?>("int?:empty", Enumerable.Max, x => EnumerableExt.Max(x, Comparer <int?> .Default));
            Aggregate <int?, int?>("int?:all null", Enumerable.Max, x => EnumerableExt.Max(x, Comparer <int?> .Default), null, null, null);
            Aggregate <int?, int?>("int?:starts null", Enumerable.Max, x => EnumerableExt.Max(x, Comparer <int?> .Default), null, 1, 2, 3, 1);
            Aggregate <int?, int?>("int?:with null", Enumerable.Max, x => EnumerableExt.Max(x, Comparer <int?> .Default), 1, 2, null, 3, 1);
            Aggregate <int, int>("int:without null", Enumerable.Max, x => EnumerableExt.Max(x, Comparer <int> .Default), 1, 2, 3, 1);
            Aggregate <int?, int?>("int?:without null", Enumerable.Max, x => EnumerableExt.Max(x, Comparer <int?> .Default), 1, 2, 3, 1);

            Aggregate <int, int>("int [proj]:empty", x => Enumerable.Max(x, y => - y), x => EnumerableExt.Max(x, y => - y, Comparer <int> .Default));
            Aggregate <int?, int?>("int? [proj]:empty", x => Enumerable.Max(x, y => - y), x => EnumerableExt.Max(x, y => - y, Comparer <int?> .Default));
            Aggregate <int?, int?>("int? [proj]:all null", x => Enumerable.Max(x, y => - y), x => EnumerableExt.Max(x, y => - y, Comparer <int?> .Default), null, null, null);
            Aggregate <int?, int?>("int? [proj]:starts null", x => Enumerable.Max(x, y => - y), x => EnumerableExt.Max(x, y => - y, Comparer <int?> .Default), null, 1, 2, 3, 1);
            Aggregate <int?, int?>("int? [proj]:with null", x => Enumerable.Max(x, y => - y), x => EnumerableExt.Max(x, y => - y, Comparer <int?> .Default), 1, 2, null, 3, 1);
            Aggregate <int, int>("int [proj]:without null", x => Enumerable.Max(x, y => - y), x => EnumerableExt.Max(x, y => - y, Comparer <int> .Default), 1, 2, 3, 1);
            Aggregate <int?, int?>("int? [proj]:without null", x => Enumerable.Max(x, y => - y), x => EnumerableExt.Max(x, y => - y, Comparer <int?> .Default), 1, 2, 3, 1);
        }