Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches
Queryable.cs
Go to the documentation of this file.
5
6namespace System.Linq;
7
8public static class Queryable
9{
10 [RequiresUnreferencedCode("Enumerating in-memory collections as IQueryable can require unreferenced code because expressions referencing IQueryable extension methods can get rebound to IEnumerable extension methods. The IEnumerable extension methods could be trimmed causing the application to fail at runtime.")]
12 {
13 if (source == null)
14 {
15 throw Error.ArgumentNull("source");
16 }
18 }
19
20 [RequiresUnreferencedCode("Enumerating in-memory collections as IQueryable can require unreferenced code because expressions referencing IQueryable extension methods can get rebound to IEnumerable extension methods. The IEnumerable extension methods could be trimmed causing the application to fail at runtime.")]
22 {
23 if (source == null)
24 {
25 throw Error.ArgumentNull("source");
26 }
27 if (source is IQueryable result)
28 {
29 return result;
30 }
32 if (type == null)
33 {
35 }
36 return EnumerableQuery.Create(type.GenericTypeArguments[0], source);
37 }
38
41 {
42 if (source == null)
43 {
44 throw Error.ArgumentNull("source");
45 }
46 if (predicate == null)
47 {
48 throw Error.ArgumentNull("predicate");
49 }
50 return source.Provider.CreateQuery<TSource>(Expression.Call(null, CachedReflectionInfo.Where_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(predicate)));
51 }
52
55 {
56 if (source == null)
57 {
58 throw Error.ArgumentNull("source");
59 }
60 if (predicate == null)
61 {
62 throw Error.ArgumentNull("predicate");
63 }
64 return source.Provider.CreateQuery<TSource>(Expression.Call(null, CachedReflectionInfo.Where_Index_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(predicate)));
65 }
66
67 [DynamicDependency("OfType`1", typeof(Enumerable))]
69 {
70 if (source == null)
71 {
72 throw Error.ArgumentNull("source");
73 }
74 return source.Provider.CreateQuery<TResult>(Expression.Call(null, CachedReflectionInfo.OfType_TResult_1(typeof(TResult)), source.Expression));
75 }
76
79 {
80 if (source == null)
81 {
82 throw Error.ArgumentNull("source");
83 }
84 return source.Provider.CreateQuery<TResult>(Expression.Call(null, CachedReflectionInfo.Cast_TResult_1(typeof(TResult)), source.Expression));
85 }
86
87 [DynamicDependency("Select`2", typeof(Enumerable))]
89 {
90 if (source == null)
91 {
92 throw Error.ArgumentNull("source");
93 }
94 if (selector == null)
95 {
96 throw Error.ArgumentNull("selector");
97 }
98 return source.Provider.CreateQuery<TResult>(Expression.Call(null, CachedReflectionInfo.Select_TSource_TResult_2(typeof(TSource), typeof(TResult)), source.Expression, Expression.Quote(selector)));
99 }
100
101 [DynamicDependency("Select`2", typeof(Enumerable))]
103 {
104 if (source == null)
105 {
106 throw Error.ArgumentNull("source");
107 }
108 if (selector == null)
109 {
110 throw Error.ArgumentNull("selector");
111 }
113 }
114
115 [DynamicDependency("SelectMany`2", typeof(Enumerable))]
117 {
118 if (source == null)
119 {
120 throw Error.ArgumentNull("source");
121 }
122 if (selector == null)
123 {
124 throw Error.ArgumentNull("selector");
125 }
127 }
128
129 [DynamicDependency("SelectMany`2", typeof(Enumerable))]
131 {
132 if (source == null)
133 {
134 throw Error.ArgumentNull("source");
135 }
136 if (selector == null)
137 {
138 throw Error.ArgumentNull("selector");
139 }
141 }
142
143 [DynamicDependency("SelectMany`3", typeof(Enumerable))]
145 {
146 if (source == null)
147 {
148 throw Error.ArgumentNull("source");
149 }
150 if (collectionSelector == null)
151 {
152 throw Error.ArgumentNull("collectionSelector");
153 }
154 if (resultSelector == null)
155 {
156 throw Error.ArgumentNull("resultSelector");
157 }
159 }
160
161 [DynamicDependency("SelectMany`3", typeof(Enumerable))]
163 {
164 if (source == null)
165 {
166 throw Error.ArgumentNull("source");
167 }
168 if (collectionSelector == null)
169 {
170 throw Error.ArgumentNull("collectionSelector");
171 }
172 if (resultSelector == null)
173 {
174 throw Error.ArgumentNull("resultSelector");
175 }
177 }
178
187
190 {
191 if (outer == null)
192 {
193 throw Error.ArgumentNull("outer");
194 }
195 if (inner == null)
196 {
197 throw Error.ArgumentNull("inner");
198 }
199 if (outerKeySelector == null)
200 {
201 throw Error.ArgumentNull("outerKeySelector");
202 }
203 if (innerKeySelector == null)
204 {
205 throw Error.ArgumentNull("innerKeySelector");
206 }
207 if (resultSelector == null)
208 {
209 throw Error.ArgumentNull("resultSelector");
210 }
212 }
213
239
240 [DynamicDependency("GroupJoin`4", typeof(Enumerable))]
242 {
243 if (outer == null)
244 {
245 throw Error.ArgumentNull("outer");
246 }
247 if (inner == null)
248 {
249 throw Error.ArgumentNull("inner");
250 }
251 if (outerKeySelector == null)
252 {
253 throw Error.ArgumentNull("outerKeySelector");
254 }
255 if (innerKeySelector == null)
256 {
257 throw Error.ArgumentNull("innerKeySelector");
258 }
259 if (resultSelector == null)
260 {
261 throw Error.ArgumentNull("resultSelector");
262 }
264 }
265
266 [DynamicDependency("GroupJoin`4", typeof(Enumerable))]
291
292 [DynamicDependency("OrderBy`2", typeof(Enumerable))]
294 {
295 if (source == null)
296 {
297 throw Error.ArgumentNull("source");
298 }
299 if (keySelector == null)
300 {
301 throw Error.ArgumentNull("keySelector");
302 }
303 return (IOrderedQueryable<TSource>)source.Provider.CreateQuery<TSource>(Expression.Call(null, CachedReflectionInfo.OrderBy_TSource_TKey_2(typeof(TSource), typeof(TKey)), source.Expression, Expression.Quote(keySelector)));
304 }
305
306 [DynamicDependency("OrderBy`2", typeof(Enumerable))]
308 {
309 if (source == null)
310 {
311 throw Error.ArgumentNull("source");
312 }
313 if (keySelector == null)
314 {
315 throw Error.ArgumentNull("keySelector");
316 }
318 }
319
320 [DynamicDependency("OrderByDescending`2", typeof(Enumerable))]
322 {
323 if (source == null)
324 {
325 throw Error.ArgumentNull("source");
326 }
327 if (keySelector == null)
328 {
329 throw Error.ArgumentNull("keySelector");
330 }
332 }
333
334 [DynamicDependency("OrderByDescending`2", typeof(Enumerable))]
336 {
337 if (source == null)
338 {
339 throw Error.ArgumentNull("source");
340 }
341 if (keySelector == null)
342 {
343 throw Error.ArgumentNull("keySelector");
344 }
346 }
347
348 [DynamicDependency("ThenBy`2", typeof(Enumerable))]
350 {
351 if (source == null)
352 {
353 throw Error.ArgumentNull("source");
354 }
355 if (keySelector == null)
356 {
357 throw Error.ArgumentNull("keySelector");
358 }
359 return (IOrderedQueryable<TSource>)source.Provider.CreateQuery<TSource>(Expression.Call(null, CachedReflectionInfo.ThenBy_TSource_TKey_2(typeof(TSource), typeof(TKey)), source.Expression, Expression.Quote(keySelector)));
360 }
361
362 [DynamicDependency("ThenBy`2", typeof(Enumerable))]
364 {
365 if (source == null)
366 {
367 throw Error.ArgumentNull("source");
368 }
369 if (keySelector == null)
370 {
371 throw Error.ArgumentNull("keySelector");
372 }
374 }
375
376 [DynamicDependency("ThenByDescending`2", typeof(Enumerable))]
378 {
379 if (source == null)
380 {
381 throw Error.ArgumentNull("source");
382 }
383 if (keySelector == null)
384 {
385 throw Error.ArgumentNull("keySelector");
386 }
387 return (IOrderedQueryable<TSource>)source.Provider.CreateQuery<TSource>(Expression.Call(null, CachedReflectionInfo.ThenByDescending_TSource_TKey_2(typeof(TSource), typeof(TKey)), source.Expression, Expression.Quote(keySelector)));
388 }
389
390 [DynamicDependency("ThenByDescending`2", typeof(Enumerable))]
403
406 {
407 if (source == null)
408 {
409 throw Error.ArgumentNull("source");
410 }
411 return source.Provider.CreateQuery<TSource>(Expression.Call(null, CachedReflectionInfo.Take_Int32_TSource_2(typeof(TSource)), source.Expression, Expression.Constant(count)));
412 }
413
416 {
417 if (source == null)
418 {
419 throw Error.ArgumentNull("source");
420 }
421 return source.Provider.CreateQuery<TSource>(Expression.Call(null, CachedReflectionInfo.Take_Range_TSource_2(typeof(TSource)), source.Expression, Expression.Constant(range)));
422 }
423
424 [DynamicDependency("TakeWhile`1", typeof(Enumerable))]
426 {
427 if (source == null)
428 {
429 throw Error.ArgumentNull("source");
430 }
431 if (predicate == null)
432 {
433 throw Error.ArgumentNull("predicate");
434 }
435 return source.Provider.CreateQuery<TSource>(Expression.Call(null, CachedReflectionInfo.TakeWhile_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(predicate)));
436 }
437
438 [DynamicDependency("TakeWhile`1", typeof(Enumerable))]
440 {
441 if (source == null)
442 {
443 throw Error.ArgumentNull("source");
444 }
445 if (predicate == null)
446 {
447 throw Error.ArgumentNull("predicate");
448 }
449 return source.Provider.CreateQuery<TSource>(Expression.Call(null, CachedReflectionInfo.TakeWhile_Index_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(predicate)));
450 }
451
454 {
455 if (source == null)
456 {
457 throw Error.ArgumentNull("source");
458 }
459 return source.Provider.CreateQuery<TSource>(Expression.Call(null, CachedReflectionInfo.Skip_TSource_2(typeof(TSource)), source.Expression, Expression.Constant(count)));
460 }
461
462 [DynamicDependency("SkipWhile`1", typeof(Enumerable))]
464 {
465 if (source == null)
466 {
467 throw Error.ArgumentNull("source");
468 }
469 if (predicate == null)
470 {
471 throw Error.ArgumentNull("predicate");
472 }
473 return source.Provider.CreateQuery<TSource>(Expression.Call(null, CachedReflectionInfo.SkipWhile_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(predicate)));
474 }
475
476 [DynamicDependency("SkipWhile`1", typeof(Enumerable))]
478 {
479 if (source == null)
480 {
481 throw Error.ArgumentNull("source");
482 }
483 if (predicate == null)
484 {
485 throw Error.ArgumentNull("predicate");
486 }
487 return source.Provider.CreateQuery<TSource>(Expression.Call(null, CachedReflectionInfo.SkipWhile_Index_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(predicate)));
488 }
489
490 [DynamicDependency("GroupBy`2", typeof(Enumerable))]
492 {
493 if (source == null)
494 {
495 throw Error.ArgumentNull("source");
496 }
497 if (keySelector == null)
498 {
499 throw Error.ArgumentNull("keySelector");
500 }
502 }
503
504 [DynamicDependency("GroupBy`3", typeof(Enumerable))]
506 {
507 if (source == null)
508 {
509 throw Error.ArgumentNull("source");
510 }
511 if (keySelector == null)
512 {
513 throw Error.ArgumentNull("keySelector");
514 }
515 if (elementSelector == null)
516 {
517 throw Error.ArgumentNull("elementSelector");
518 }
520 }
521
522 [DynamicDependency("GroupBy`2", typeof(Enumerable))]
535
536 [DynamicDependency("GroupBy`3", typeof(Enumerable))]
553
554 [DynamicDependency("GroupBy`4", typeof(Enumerable))]
556 {
557 if (source == null)
558 {
559 throw Error.ArgumentNull("source");
560 }
561 if (keySelector == null)
562 {
563 throw Error.ArgumentNull("keySelector");
564 }
565 if (elementSelector == null)
566 {
567 throw Error.ArgumentNull("elementSelector");
568 }
569 if (resultSelector == null)
570 {
571 throw Error.ArgumentNull("resultSelector");
572 }
574 }
575
576 [DynamicDependency("GroupBy`3", typeof(Enumerable))]
578 {
579 if (source == null)
580 {
581 throw Error.ArgumentNull("source");
582 }
583 if (keySelector == null)
584 {
585 throw Error.ArgumentNull("keySelector");
586 }
587 if (resultSelector == null)
588 {
589 throw Error.ArgumentNull("resultSelector");
590 }
592 }
593
594 [DynamicDependency("GroupBy`3", typeof(Enumerable))]
596 {
597 if (source == null)
598 {
599 throw Error.ArgumentNull("source");
600 }
601 if (keySelector == null)
602 {
603 throw Error.ArgumentNull("keySelector");
604 }
605 if (resultSelector == null)
606 {
607 throw Error.ArgumentNull("resultSelector");
608 }
610 }
611
612 [DynamicDependency("GroupBy`4", typeof(Enumerable))]
633
634 [DynamicDependency("Distinct`1", typeof(Enumerable))]
636 {
637 if (source == null)
638 {
639 throw Error.ArgumentNull("source");
640 }
641 return source.Provider.CreateQuery<TSource>(Expression.Call(null, CachedReflectionInfo.Distinct_TSource_1(typeof(TSource)), source.Expression));
642 }
643
644 [DynamicDependency("Distinct`1", typeof(Enumerable))]
646 {
647 if (source == null)
648 {
649 throw Error.ArgumentNull("source");
650 }
651 return source.Provider.CreateQuery<TSource>(Expression.Call(null, CachedReflectionInfo.Distinct_TSource_2(typeof(TSource)), source.Expression, Expression.Constant(comparer, typeof(IEqualityComparer<TSource>))));
652 }
653
654 [DynamicDependency("DistinctBy`2", typeof(Enumerable))]
656 {
657 if (source == null)
658 {
659 throw Error.ArgumentNull("source");
660 }
661 if (keySelector == null)
662 {
663 throw Error.ArgumentNull("keySelector");
664 }
665 return source.Provider.CreateQuery<TSource>(Expression.Call(null, CachedReflectionInfo.DistinctBy_TSource_TKey_2(typeof(TSource), typeof(TKey)), source.Expression, Expression.Quote(keySelector)));
666 }
667
668 [DynamicDependency("DistinctBy`2", typeof(Enumerable))]
670 {
671 if (source == null)
672 {
673 throw Error.ArgumentNull("source");
674 }
675 if (keySelector == null)
676 {
677 throw Error.ArgumentNull("keySelector");
678 }
680 }
681
682 [DynamicDependency("Chunk`1", typeof(Enumerable))]
684 {
685 if (source == null)
686 {
687 throw Error.ArgumentNull("source");
688 }
689 return source.Provider.CreateQuery<TSource[]>(Expression.Call(null, CachedReflectionInfo.Chunk_TSource_1(typeof(TSource)), source.Expression, Expression.Constant(size)));
690 }
691
692 [DynamicDependency("Concat`1", typeof(Enumerable))]
694 {
695 if (source1 == null)
696 {
697 throw Error.ArgumentNull("source1");
698 }
699 if (source2 == null)
700 {
701 throw Error.ArgumentNull("source2");
702 }
703 return source1.Provider.CreateQuery<TSource>(Expression.Call(null, CachedReflectionInfo.Concat_TSource_2(typeof(TSource)), source1.Expression, GetSourceExpression(source2)));
704 }
705
708 {
709 if (source1 == null)
710 {
711 throw Error.ArgumentNull("source1");
712 }
713 if (source2 == null)
714 {
715 throw Error.ArgumentNull("source2");
716 }
718 }
719
722 {
723 if (source1 == null)
724 {
725 throw Error.ArgumentNull("source1");
726 }
727 if (source2 == null)
728 {
729 throw Error.ArgumentNull("source2");
730 }
731 if (resultSelector == null)
732 {
733 throw Error.ArgumentNull("resultSelector");
734 }
736 }
737
740 {
741 if (source1 == null)
742 {
743 throw Error.ArgumentNull("source1");
744 }
745 if (source2 == null)
746 {
747 throw Error.ArgumentNull("source2");
748 }
749 if (source3 == null)
750 {
751 throw Error.ArgumentNull("source3");
752 }
754 }
755
756 [DynamicDependency("Union`1", typeof(Enumerable))]
758 {
759 if (source1 == null)
760 {
761 throw Error.ArgumentNull("source1");
762 }
763 if (source2 == null)
764 {
765 throw Error.ArgumentNull("source2");
766 }
767 return source1.Provider.CreateQuery<TSource>(Expression.Call(null, CachedReflectionInfo.Union_TSource_2(typeof(TSource)), source1.Expression, GetSourceExpression(source2)));
768 }
769
770 [DynamicDependency("Union`1", typeof(Enumerable))]
772 {
773 if (source1 == null)
774 {
775 throw Error.ArgumentNull("source1");
776 }
777 if (source2 == null)
778 {
779 throw Error.ArgumentNull("source2");
780 }
782 }
783
784 [DynamicDependency("UnionBy`2", typeof(Enumerable))]
786 {
787 if (source1 == null)
788 {
789 throw Error.ArgumentNull("source1");
790 }
791 if (source2 == null)
792 {
793 throw Error.ArgumentNull("source2");
794 }
795 if (keySelector == null)
796 {
797 throw Error.ArgumentNull("keySelector");
798 }
799 return source1.Provider.CreateQuery<TSource>(Expression.Call(null, CachedReflectionInfo.UnionBy_TSource_TKey_3(typeof(TSource), typeof(TKey)), source1.Expression, GetSourceExpression(source2), Expression.Quote(keySelector)));
800 }
801
802 [DynamicDependency("UnionBy`2", typeof(Enumerable))]
804 {
805 if (source1 == null)
806 {
807 throw Error.ArgumentNull("source1");
808 }
809 if (source2 == null)
810 {
811 throw Error.ArgumentNull("source2");
812 }
813 if (keySelector == null)
814 {
815 throw Error.ArgumentNull("keySelector");
816 }
818 }
819
820 [DynamicDependency("Intersect`1", typeof(Enumerable))]
822 {
823 if (source1 == null)
824 {
825 throw Error.ArgumentNull("source1");
826 }
827 if (source2 == null)
828 {
829 throw Error.ArgumentNull("source2");
830 }
831 return source1.Provider.CreateQuery<TSource>(Expression.Call(null, CachedReflectionInfo.Intersect_TSource_2(typeof(TSource)), source1.Expression, GetSourceExpression(source2)));
832 }
833
834 [DynamicDependency("Intersect`1", typeof(Enumerable))]
836 {
837 if (source1 == null)
838 {
839 throw Error.ArgumentNull("source1");
840 }
841 if (source2 == null)
842 {
843 throw Error.ArgumentNull("source2");
844 }
846 }
847
848 [DynamicDependency("IntersectBy`2", typeof(Enumerable))]
850 {
851 if (source1 == null)
852 {
853 throw Error.ArgumentNull("source1");
854 }
855 if (source2 == null)
856 {
857 throw Error.ArgumentNull("source2");
858 }
859 if (keySelector == null)
860 {
861 throw Error.ArgumentNull("keySelector");
862 }
863 return source1.Provider.CreateQuery<TSource>(Expression.Call(null, CachedReflectionInfo.IntersectBy_TSource_TKey_3(typeof(TSource), typeof(TKey)), source1.Expression, GetSourceExpression(source2), Expression.Quote(keySelector)));
864 }
865
866 [DynamicDependency("IntersectBy`2", typeof(Enumerable))]
868 {
869 if (source1 == null)
870 {
871 throw Error.ArgumentNull("source1");
872 }
873 if (source2 == null)
874 {
875 throw Error.ArgumentNull("source2");
876 }
877 if (keySelector == null)
878 {
879 throw Error.ArgumentNull("keySelector");
880 }
882 }
883
884 [DynamicDependency("Except`1", typeof(Enumerable))]
886 {
887 if (source1 == null)
888 {
889 throw Error.ArgumentNull("source1");
890 }
891 if (source2 == null)
892 {
893 throw Error.ArgumentNull("source2");
894 }
895 return source1.Provider.CreateQuery<TSource>(Expression.Call(null, CachedReflectionInfo.Except_TSource_2(typeof(TSource)), source1.Expression, GetSourceExpression(source2)));
896 }
897
898 [DynamicDependency("Except`1", typeof(Enumerable))]
900 {
901 if (source1 == null)
902 {
903 throw Error.ArgumentNull("source1");
904 }
905 if (source2 == null)
906 {
907 throw Error.ArgumentNull("source2");
908 }
910 }
911
912 [DynamicDependency("ExceptBy`2", typeof(Enumerable))]
914 {
915 if (source1 == null)
916 {
917 throw Error.ArgumentNull("source1");
918 }
919 if (source2 == null)
920 {
921 throw Error.ArgumentNull("source2");
922 }
923 if (keySelector == null)
924 {
925 throw Error.ArgumentNull("keySelector");
926 }
927 return source1.Provider.CreateQuery<TSource>(Expression.Call(null, CachedReflectionInfo.ExceptBy_TSource_TKey_3(typeof(TSource), typeof(TKey)), source1.Expression, GetSourceExpression(source2), Expression.Quote(keySelector)));
928 }
929
930 [DynamicDependency("ExceptBy`2", typeof(Enumerable))]
932 {
933 if (source1 == null)
934 {
935 throw Error.ArgumentNull("source1");
936 }
937 if (source2 == null)
938 {
939 throw Error.ArgumentNull("source2");
940 }
941 if (keySelector == null)
942 {
943 throw Error.ArgumentNull("keySelector");
944 }
946 }
947
948 [DynamicDependency("First`1", typeof(Enumerable))]
949 public static TSource First<TSource>(this IQueryable<TSource> source)
950 {
951 if (source == null)
952 {
953 throw Error.ArgumentNull("source");
954 }
955 return source.Provider.Execute<TSource>(Expression.Call(null, CachedReflectionInfo.First_TSource_1(typeof(TSource)), source.Expression));
956 }
957
958 [DynamicDependency("First`1", typeof(Enumerable))]
960 {
961 if (source == null)
962 {
963 throw Error.ArgumentNull("source");
964 }
965 if (predicate == null)
966 {
967 throw Error.ArgumentNull("predicate");
968 }
969 return source.Provider.Execute<TSource>(Expression.Call(null, CachedReflectionInfo.First_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(predicate)));
970 }
971
972 [DynamicDependency("FirstOrDefault`1", typeof(Enumerable))]
974 {
975 if (source == null)
976 {
977 throw Error.ArgumentNull("source");
978 }
979 return source.Provider.Execute<TSource>(Expression.Call(null, CachedReflectionInfo.FirstOrDefault_TSource_1(typeof(TSource)), source.Expression));
980 }
981
982 [DynamicDependency("FirstOrDefault`1", typeof(Enumerable))]
984 {
985 if (source == null)
986 {
987 throw Error.ArgumentNull("source");
988 }
989 return source.Provider.Execute<TSource>(Expression.Call(null, CachedReflectionInfo.FirstOrDefault_TSource_3(typeof(TSource)), source.Expression, Expression.Constant(defaultValue, typeof(TSource))));
990 }
991
992 [DynamicDependency("FirstOrDefault`1", typeof(Enumerable))]
994 {
995 if (source == null)
996 {
997 throw Error.ArgumentNull("source");
998 }
999 if (predicate == null)
1000 {
1001 throw Error.ArgumentNull("predicate");
1002 }
1003 return source.Provider.Execute<TSource>(Expression.Call(null, CachedReflectionInfo.FirstOrDefault_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(predicate)));
1004 }
1005
1006 [DynamicDependency("FirstOrDefault`1", typeof(Enumerable))]
1008 {
1009 if (source == null)
1010 {
1011 throw Error.ArgumentNull("source");
1012 }
1013 if (predicate == null)
1014 {
1015 throw Error.ArgumentNull("predicate");
1016 }
1017 return source.Provider.Execute<TSource>(Expression.Call(null, CachedReflectionInfo.FirstOrDefault_TSource_4(typeof(TSource)), source.Expression, Expression.Quote(predicate), Expression.Constant(defaultValue, typeof(TSource))));
1018 }
1019
1020 [DynamicDependency("Last`1", typeof(Enumerable))]
1021 public static TSource Last<TSource>(this IQueryable<TSource> source)
1022 {
1023 if (source == null)
1024 {
1025 throw Error.ArgumentNull("source");
1026 }
1027 return source.Provider.Execute<TSource>(Expression.Call(null, CachedReflectionInfo.Last_TSource_1(typeof(TSource)), source.Expression));
1028 }
1029
1030 [DynamicDependency("Last`1", typeof(Enumerable))]
1032 {
1033 if (source == null)
1034 {
1035 throw Error.ArgumentNull("source");
1036 }
1037 if (predicate == null)
1038 {
1039 throw Error.ArgumentNull("predicate");
1040 }
1041 return source.Provider.Execute<TSource>(Expression.Call(null, CachedReflectionInfo.Last_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(predicate)));
1042 }
1043
1044 [DynamicDependency("LastOrDefault`1", typeof(Enumerable))]
1046 {
1047 if (source == null)
1048 {
1049 throw Error.ArgumentNull("source");
1050 }
1051 return source.Provider.Execute<TSource>(Expression.Call(null, CachedReflectionInfo.LastOrDefault_TSource_1(typeof(TSource)), source.Expression));
1052 }
1053
1054 [DynamicDependency("LastOrDefault`1", typeof(Enumerable))]
1056 {
1057 if (source == null)
1058 {
1059 throw Error.ArgumentNull("source");
1060 }
1061 return source.Provider.Execute<TSource>(Expression.Call(null, CachedReflectionInfo.LastOrDefault_TSource_3(typeof(TSource)), source.Expression, Expression.Constant(defaultValue, typeof(TSource))));
1062 }
1063
1064 [DynamicDependency("LastOrDefault`1", typeof(Enumerable))]
1066 {
1067 if (source == null)
1068 {
1069 throw Error.ArgumentNull("source");
1070 }
1071 if (predicate == null)
1072 {
1073 throw Error.ArgumentNull("predicate");
1074 }
1075 return source.Provider.Execute<TSource>(Expression.Call(null, CachedReflectionInfo.LastOrDefault_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(predicate)));
1076 }
1077
1078 [DynamicDependency("LastOrDefault`1", typeof(Enumerable))]
1080 {
1081 if (source == null)
1082 {
1083 throw Error.ArgumentNull("source");
1084 }
1085 if (predicate == null)
1086 {
1087 throw Error.ArgumentNull("predicate");
1088 }
1089 return source.Provider.Execute<TSource>(Expression.Call(null, CachedReflectionInfo.LastOrDefault_TSource_4(typeof(TSource)), source.Expression, Expression.Quote(predicate), Expression.Constant(defaultValue, typeof(TSource))));
1090 }
1091
1092 [DynamicDependency("Single`1", typeof(Enumerable))]
1093 public static TSource Single<TSource>(this IQueryable<TSource> source)
1094 {
1095 if (source == null)
1096 {
1097 throw Error.ArgumentNull("source");
1098 }
1099 return source.Provider.Execute<TSource>(Expression.Call(null, CachedReflectionInfo.Single_TSource_1(typeof(TSource)), source.Expression));
1100 }
1101
1102 [DynamicDependency("Single`1", typeof(Enumerable))]
1104 {
1105 if (source == null)
1106 {
1107 throw Error.ArgumentNull("source");
1108 }
1109 if (predicate == null)
1110 {
1111 throw Error.ArgumentNull("predicate");
1112 }
1113 return source.Provider.Execute<TSource>(Expression.Call(null, CachedReflectionInfo.Single_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(predicate)));
1114 }
1115
1116 [DynamicDependency("SingleOrDefault`1", typeof(Enumerable))]
1118 {
1119 if (source == null)
1120 {
1121 throw Error.ArgumentNull("source");
1122 }
1123 return source.Provider.Execute<TSource>(Expression.Call(null, CachedReflectionInfo.SingleOrDefault_TSource_1(typeof(TSource)), source.Expression));
1124 }
1125
1126 [DynamicDependency("SingleOrDefault`1", typeof(Enumerable))]
1128 {
1129 if (source == null)
1130 {
1131 throw Error.ArgumentNull("source");
1132 }
1133 return source.Provider.Execute<TSource>(Expression.Call(null, CachedReflectionInfo.SingleOrDefault_TSource_3(typeof(TSource)), source.Expression, Expression.Constant(defaultValue, typeof(TSource))));
1134 }
1135
1136 [DynamicDependency("SingleOrDefault`1", typeof(Enumerable))]
1138 {
1139 if (source == null)
1140 {
1141 throw Error.ArgumentNull("source");
1142 }
1143 if (predicate == null)
1144 {
1145 throw Error.ArgumentNull("predicate");
1146 }
1147 return source.Provider.Execute<TSource>(Expression.Call(null, CachedReflectionInfo.SingleOrDefault_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(predicate)));
1148 }
1149
1150 [DynamicDependency("SingleOrDefault`1", typeof(Enumerable))]
1152 {
1153 if (source == null)
1154 {
1155 throw Error.ArgumentNull("source");
1156 }
1157 if (predicate == null)
1158 {
1159 throw Error.ArgumentNull("predicate");
1160 }
1161 return source.Provider.Execute<TSource>(Expression.Call(null, CachedReflectionInfo.SingleOrDefault_TSource_4(typeof(TSource)), source.Expression, Expression.Quote(predicate), Expression.Constant(defaultValue, typeof(TSource))));
1162 }
1163
1164 [DynamicDependency("ElementAt`1", typeof(Enumerable))]
1165 public static TSource ElementAt<TSource>(this IQueryable<TSource> source, int index)
1166 {
1167 if (source == null)
1168 {
1169 throw Error.ArgumentNull("source");
1170 }
1171 if (index < 0)
1172 {
1173 throw Error.ArgumentOutOfRange("index");
1174 }
1175 return source.Provider.Execute<TSource>(Expression.Call(null, CachedReflectionInfo.ElementAt_Int32_TSource_2(typeof(TSource)), source.Expression, Expression.Constant(index)));
1176 }
1177
1178 [DynamicDependency("ElementAt`1", typeof(Enumerable))]
1180 {
1181 if (source == null)
1182 {
1183 throw Error.ArgumentNull("source");
1184 }
1185 if (index.IsFromEnd && index.Value == 0)
1186 {
1187 throw Error.ArgumentOutOfRange("index");
1188 }
1189 return source.Provider.Execute<TSource>(Expression.Call(null, CachedReflectionInfo.ElementAt_Index_TSource_2(typeof(TSource)), source.Expression, Expression.Constant(index)));
1190 }
1191
1192 [DynamicDependency("ElementAtOrDefault`1", typeof(Enumerable))]
1194 {
1195 if (source == null)
1196 {
1197 throw Error.ArgumentNull("source");
1198 }
1199 return source.Provider.Execute<TSource>(Expression.Call(null, CachedReflectionInfo.ElementAtOrDefault_Int32_TSource_2(typeof(TSource)), source.Expression, Expression.Constant(index)));
1200 }
1201
1202 [DynamicDependency("ElementAtOrDefault`1", typeof(Enumerable))]
1204 {
1205 if (source == null)
1206 {
1207 throw Error.ArgumentNull("source");
1208 }
1209 return source.Provider.Execute<TSource>(Expression.Call(null, CachedReflectionInfo.ElementAtOrDefault_Index_TSource_2(typeof(TSource)), source.Expression, Expression.Constant(index)));
1210 }
1211
1212 [DynamicDependency("DefaultIfEmpty`1", typeof(Enumerable))]
1214 {
1215 if (source == null)
1216 {
1217 throw Error.ArgumentNull("source");
1218 }
1219 return source.Provider.CreateQuery<TSource>(Expression.Call(null, CachedReflectionInfo.DefaultIfEmpty_TSource_1(typeof(TSource)), source.Expression));
1220 }
1221
1222 [DynamicDependency("DefaultIfEmpty`1", typeof(Enumerable))]
1224 {
1225 if (source == null)
1226 {
1227 throw Error.ArgumentNull("source");
1228 }
1229 return source.Provider.CreateQuery<TSource>(Expression.Call(null, CachedReflectionInfo.DefaultIfEmpty_TSource_2(typeof(TSource)), source.Expression, Expression.Constant(defaultValue, typeof(TSource))));
1230 }
1231
1232 [DynamicDependency("Contains`1", typeof(Enumerable))]
1233 public static bool Contains<TSource>(this IQueryable<TSource> source, TSource item)
1234 {
1235 if (source == null)
1236 {
1237 throw Error.ArgumentNull("source");
1238 }
1239 return source.Provider.Execute<bool>(Expression.Call(null, CachedReflectionInfo.Contains_TSource_2(typeof(TSource)), source.Expression, Expression.Constant(item, typeof(TSource))));
1240 }
1241
1242 [DynamicDependency("Contains`1", typeof(Enumerable))]
1244 {
1245 if (source == null)
1246 {
1247 throw Error.ArgumentNull("source");
1248 }
1250 }
1251
1252 [DynamicDependency("Reverse`1", typeof(Enumerable))]
1254 {
1255 if (source == null)
1256 {
1257 throw Error.ArgumentNull("source");
1258 }
1259 return source.Provider.CreateQuery<TSource>(Expression.Call(null, CachedReflectionInfo.Reverse_TSource_1(typeof(TSource)), source.Expression));
1260 }
1261
1262 [DynamicDependency("SequenceEqual`1", typeof(Enumerable))]
1264 {
1265 if (source1 == null)
1266 {
1267 throw Error.ArgumentNull("source1");
1268 }
1269 if (source2 == null)
1270 {
1271 throw Error.ArgumentNull("source2");
1272 }
1273 return source1.Provider.Execute<bool>(Expression.Call(null, CachedReflectionInfo.SequenceEqual_TSource_2(typeof(TSource)), source1.Expression, GetSourceExpression(source2)));
1274 }
1275
1276 [DynamicDependency("SequenceEqual`1", typeof(Enumerable))]
1278 {
1279 if (source1 == null)
1280 {
1281 throw Error.ArgumentNull("source1");
1282 }
1283 if (source2 == null)
1284 {
1285 throw Error.ArgumentNull("source2");
1286 }
1288 }
1289
1291 public static bool Any<TSource>(this IQueryable<TSource> source)
1292 {
1293 if (source == null)
1294 {
1295 throw Error.ArgumentNull("source");
1296 }
1297 return source.Provider.Execute<bool>(Expression.Call(null, CachedReflectionInfo.Any_TSource_1(typeof(TSource)), source.Expression));
1298 }
1299
1302 {
1303 if (source == null)
1304 {
1305 throw Error.ArgumentNull("source");
1306 }
1307 if (predicate == null)
1308 {
1309 throw Error.ArgumentNull("predicate");
1310 }
1311 return source.Provider.Execute<bool>(Expression.Call(null, CachedReflectionInfo.Any_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(predicate)));
1312 }
1313
1316 {
1317 if (source == null)
1318 {
1319 throw Error.ArgumentNull("source");
1320 }
1321 if (predicate == null)
1322 {
1323 throw Error.ArgumentNull("predicate");
1324 }
1325 return source.Provider.Execute<bool>(Expression.Call(null, CachedReflectionInfo.All_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(predicate)));
1326 }
1327
1328 [DynamicDependency("Count`1", typeof(Enumerable))]
1330 {
1331 if (source == null)
1332 {
1333 throw Error.ArgumentNull("source");
1334 }
1335 return source.Provider.Execute<int>(Expression.Call(null, CachedReflectionInfo.Count_TSource_1(typeof(TSource)), source.Expression));
1336 }
1337
1338 [DynamicDependency("Count`1", typeof(Enumerable))]
1340 {
1341 if (source == null)
1342 {
1343 throw Error.ArgumentNull("source");
1344 }
1345 if (predicate == null)
1346 {
1347 throw Error.ArgumentNull("predicate");
1348 }
1349 return source.Provider.Execute<int>(Expression.Call(null, CachedReflectionInfo.Count_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(predicate)));
1350 }
1351
1352 [DynamicDependency("LongCount`1", typeof(Enumerable))]
1354 {
1355 if (source == null)
1356 {
1357 throw Error.ArgumentNull("source");
1358 }
1359 return source.Provider.Execute<long>(Expression.Call(null, CachedReflectionInfo.LongCount_TSource_1(typeof(TSource)), source.Expression));
1360 }
1361
1362 [DynamicDependency("LongCount`1", typeof(Enumerable))]
1364 {
1365 if (source == null)
1366 {
1367 throw Error.ArgumentNull("source");
1368 }
1369 if (predicate == null)
1370 {
1371 throw Error.ArgumentNull("predicate");
1372 }
1373 return source.Provider.Execute<long>(Expression.Call(null, CachedReflectionInfo.LongCount_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(predicate)));
1374 }
1375
1377 public static TSource? Min<TSource>(this IQueryable<TSource> source)
1378 {
1379 if (source == null)
1380 {
1381 throw Error.ArgumentNull("source");
1382 }
1383 return source.Provider.Execute<TSource>(Expression.Call(null, CachedReflectionInfo.Min_TSource_1(typeof(TSource)), source.Expression));
1384 }
1385
1388 {
1389 if (source == null)
1390 {
1391 throw Error.ArgumentNull("source");
1392 }
1393 return source.Provider.Execute<TSource>(Expression.Call(null, CachedReflectionInfo.Min_TSource_2(typeof(TSource)), source.Expression, Expression.Constant(comparer, typeof(IComparer<TSource>))));
1394 }
1395
1398 {
1399 if (source == null)
1400 {
1401 throw Error.ArgumentNull("source");
1402 }
1403 if (selector == null)
1404 {
1405 throw Error.ArgumentNull("selector");
1406 }
1407 return source.Provider.Execute<TResult>(Expression.Call(null, CachedReflectionInfo.Min_TSource_TResult_2(typeof(TSource), typeof(TResult)), source.Expression, Expression.Quote(selector)));
1408 }
1409
1410 [DynamicDependency("MinBy`2", typeof(Enumerable))]
1412 {
1413 if (source == null)
1414 {
1415 throw Error.ArgumentNull("source");
1416 }
1417 if (keySelector == null)
1418 {
1419 throw Error.ArgumentNull("keySelector");
1420 }
1421 return source.Provider.Execute<TSource>(Expression.Call(null, CachedReflectionInfo.MinBy_TSource_TKey_2(typeof(TSource), typeof(TKey)), source.Expression, Expression.Quote(keySelector)));
1422 }
1423
1424 [DynamicDependency("MinBy`2", typeof(Enumerable))]
1426 {
1427 if (source == null)
1428 {
1429 throw Error.ArgumentNull("source");
1430 }
1431 if (keySelector == null)
1432 {
1433 throw Error.ArgumentNull("keySelector");
1434 }
1436 }
1437
1439 public static TSource? Max<TSource>(this IQueryable<TSource> source)
1440 {
1441 if (source == null)
1442 {
1443 throw Error.ArgumentNull("source");
1444 }
1445 return source.Provider.Execute<TSource>(Expression.Call(null, CachedReflectionInfo.Max_TSource_1(typeof(TSource)), source.Expression));
1446 }
1447
1450 {
1451 if (source == null)
1452 {
1453 throw Error.ArgumentNull("source");
1454 }
1455 return source.Provider.Execute<TSource>(Expression.Call(null, CachedReflectionInfo.Max_TSource_2(typeof(TSource)), source.Expression, Expression.Constant(comparer, typeof(IComparer<TSource>))));
1456 }
1457
1460 {
1461 if (source == null)
1462 {
1463 throw Error.ArgumentNull("source");
1464 }
1465 if (selector == null)
1466 {
1467 throw Error.ArgumentNull("selector");
1468 }
1469 return source.Provider.Execute<TResult>(Expression.Call(null, CachedReflectionInfo.Max_TSource_TResult_2(typeof(TSource), typeof(TResult)), source.Expression, Expression.Quote(selector)));
1470 }
1471
1472 [DynamicDependency("MaxBy`2", typeof(Enumerable))]
1474 {
1475 if (source == null)
1476 {
1477 throw Error.ArgumentNull("source");
1478 }
1479 if (keySelector == null)
1480 {
1481 throw Error.ArgumentNull("keySelector");
1482 }
1483 return source.Provider.Execute<TSource>(Expression.Call(null, CachedReflectionInfo.MaxBy_TSource_TKey_2(typeof(TSource), typeof(TKey)), source.Expression, Expression.Quote(keySelector)));
1484 }
1485
1486 [DynamicDependency("MaxBy`2", typeof(Enumerable))]
1488 {
1489 if (source == null)
1490 {
1491 throw Error.ArgumentNull("source");
1492 }
1493 if (keySelector == null)
1494 {
1495 throw Error.ArgumentNull("keySelector");
1496 }
1498 }
1499
1501 public static int Sum(this IQueryable<int> source)
1502 {
1503 if (source == null)
1504 {
1505 throw Error.ArgumentNull("source");
1506 }
1507 return source.Provider.Execute<int>(Expression.Call(null, CachedReflectionInfo.Sum_Int32_1, source.Expression));
1508 }
1509
1511 public static int? Sum(this IQueryable<int?> source)
1512 {
1513 if (source == null)
1514 {
1515 throw Error.ArgumentNull("source");
1516 }
1517 return source.Provider.Execute<int?>(Expression.Call(null, CachedReflectionInfo.Sum_NullableInt32_1, source.Expression));
1518 }
1519
1521 public static long Sum(this IQueryable<long> source)
1522 {
1523 if (source == null)
1524 {
1525 throw Error.ArgumentNull("source");
1526 }
1527 return source.Provider.Execute<long>(Expression.Call(null, CachedReflectionInfo.Sum_Int64_1, source.Expression));
1528 }
1529
1531 public static long? Sum(this IQueryable<long?> source)
1532 {
1533 if (source == null)
1534 {
1535 throw Error.ArgumentNull("source");
1536 }
1537 return source.Provider.Execute<long?>(Expression.Call(null, CachedReflectionInfo.Sum_NullableInt64_1, source.Expression));
1538 }
1539
1541 public static float Sum(this IQueryable<float> source)
1542 {
1543 if (source == null)
1544 {
1545 throw Error.ArgumentNull("source");
1546 }
1547 return source.Provider.Execute<float>(Expression.Call(null, CachedReflectionInfo.Sum_Single_1, source.Expression));
1548 }
1549
1551 public static float? Sum(this IQueryable<float?> source)
1552 {
1553 if (source == null)
1554 {
1555 throw Error.ArgumentNull("source");
1556 }
1557 return source.Provider.Execute<float?>(Expression.Call(null, CachedReflectionInfo.Sum_NullableSingle_1, source.Expression));
1558 }
1559
1561 public static double Sum(this IQueryable<double> source)
1562 {
1563 if (source == null)
1564 {
1565 throw Error.ArgumentNull("source");
1566 }
1567 return source.Provider.Execute<double>(Expression.Call(null, CachedReflectionInfo.Sum_Double_1, source.Expression));
1568 }
1569
1571 public static double? Sum(this IQueryable<double?> source)
1572 {
1573 if (source == null)
1574 {
1575 throw Error.ArgumentNull("source");
1576 }
1577 return source.Provider.Execute<double?>(Expression.Call(null, CachedReflectionInfo.Sum_NullableDouble_1, source.Expression));
1578 }
1579
1581 public static decimal Sum(this IQueryable<decimal> source)
1582 {
1583 if (source == null)
1584 {
1585 throw Error.ArgumentNull("source");
1586 }
1587 return source.Provider.Execute<decimal>(Expression.Call(null, CachedReflectionInfo.Sum_Decimal_1, source.Expression));
1588 }
1589
1591 public static decimal? Sum(this IQueryable<decimal?> source)
1592 {
1593 if (source == null)
1594 {
1595 throw Error.ArgumentNull("source");
1596 }
1597 return source.Provider.Execute<decimal?>(Expression.Call(null, CachedReflectionInfo.Sum_NullableDecimal_1, source.Expression));
1598 }
1599
1602 {
1603 if (source == null)
1604 {
1605 throw Error.ArgumentNull("source");
1606 }
1607 if (selector == null)
1608 {
1609 throw Error.ArgumentNull("selector");
1610 }
1611 return source.Provider.Execute<int>(Expression.Call(null, CachedReflectionInfo.Sum_Int32_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(selector)));
1612 }
1613
1616 {
1617 if (source == null)
1618 {
1619 throw Error.ArgumentNull("source");
1620 }
1621 if (selector == null)
1622 {
1623 throw Error.ArgumentNull("selector");
1624 }
1625 return source.Provider.Execute<int?>(Expression.Call(null, CachedReflectionInfo.Sum_NullableInt32_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(selector)));
1626 }
1627
1630 {
1631 if (source == null)
1632 {
1633 throw Error.ArgumentNull("source");
1634 }
1635 if (selector == null)
1636 {
1637 throw Error.ArgumentNull("selector");
1638 }
1639 return source.Provider.Execute<long>(Expression.Call(null, CachedReflectionInfo.Sum_Int64_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(selector)));
1640 }
1641
1644 {
1645 if (source == null)
1646 {
1647 throw Error.ArgumentNull("source");
1648 }
1649 if (selector == null)
1650 {
1651 throw Error.ArgumentNull("selector");
1652 }
1653 return source.Provider.Execute<long?>(Expression.Call(null, CachedReflectionInfo.Sum_NullableInt64_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(selector)));
1654 }
1655
1658 {
1659 if (source == null)
1660 {
1661 throw Error.ArgumentNull("source");
1662 }
1663 if (selector == null)
1664 {
1665 throw Error.ArgumentNull("selector");
1666 }
1667 return source.Provider.Execute<float>(Expression.Call(null, CachedReflectionInfo.Sum_Single_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(selector)));
1668 }
1669
1672 {
1673 if (source == null)
1674 {
1675 throw Error.ArgumentNull("source");
1676 }
1677 if (selector == null)
1678 {
1679 throw Error.ArgumentNull("selector");
1680 }
1681 return source.Provider.Execute<float?>(Expression.Call(null, CachedReflectionInfo.Sum_NullableSingle_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(selector)));
1682 }
1683
1686 {
1687 if (source == null)
1688 {
1689 throw Error.ArgumentNull("source");
1690 }
1691 if (selector == null)
1692 {
1693 throw Error.ArgumentNull("selector");
1694 }
1695 return source.Provider.Execute<double>(Expression.Call(null, CachedReflectionInfo.Sum_Double_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(selector)));
1696 }
1697
1700 {
1701 if (source == null)
1702 {
1703 throw Error.ArgumentNull("source");
1704 }
1705 if (selector == null)
1706 {
1707 throw Error.ArgumentNull("selector");
1708 }
1709 return source.Provider.Execute<double?>(Expression.Call(null, CachedReflectionInfo.Sum_NullableDouble_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(selector)));
1710 }
1711
1714 {
1715 if (source == null)
1716 {
1717 throw Error.ArgumentNull("source");
1718 }
1719 if (selector == null)
1720 {
1721 throw Error.ArgumentNull("selector");
1722 }
1723 return source.Provider.Execute<decimal>(Expression.Call(null, CachedReflectionInfo.Sum_Decimal_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(selector)));
1724 }
1725
1728 {
1729 if (source == null)
1730 {
1731 throw Error.ArgumentNull("source");
1732 }
1733 if (selector == null)
1734 {
1735 throw Error.ArgumentNull("selector");
1736 }
1737 return source.Provider.Execute<decimal?>(Expression.Call(null, CachedReflectionInfo.Sum_NullableDecimal_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(selector)));
1738 }
1739
1740 [DynamicDependency("Average", typeof(Enumerable))]
1741 public static double Average(this IQueryable<int> source)
1742 {
1743 if (source == null)
1744 {
1745 throw Error.ArgumentNull("source");
1746 }
1747 return source.Provider.Execute<double>(Expression.Call(null, CachedReflectionInfo.Average_Int32_1, source.Expression));
1748 }
1749
1750 [DynamicDependency("Average", typeof(Enumerable))]
1751 public static double? Average(this IQueryable<int?> source)
1752 {
1753 if (source == null)
1754 {
1755 throw Error.ArgumentNull("source");
1756 }
1757 return source.Provider.Execute<double?>(Expression.Call(null, CachedReflectionInfo.Average_NullableInt32_1, source.Expression));
1758 }
1759
1760 [DynamicDependency("Average", typeof(Enumerable))]
1761 public static double Average(this IQueryable<long> source)
1762 {
1763 if (source == null)
1764 {
1765 throw Error.ArgumentNull("source");
1766 }
1767 return source.Provider.Execute<double>(Expression.Call(null, CachedReflectionInfo.Average_Int64_1, source.Expression));
1768 }
1769
1770 [DynamicDependency("Average", typeof(Enumerable))]
1771 public static double? Average(this IQueryable<long?> source)
1772 {
1773 if (source == null)
1774 {
1775 throw Error.ArgumentNull("source");
1776 }
1777 return source.Provider.Execute<double?>(Expression.Call(null, CachedReflectionInfo.Average_NullableInt64_1, source.Expression));
1778 }
1779
1780 [DynamicDependency("Average", typeof(Enumerable))]
1781 public static float Average(this IQueryable<float> source)
1782 {
1783 if (source == null)
1784 {
1785 throw Error.ArgumentNull("source");
1786 }
1787 return source.Provider.Execute<float>(Expression.Call(null, CachedReflectionInfo.Average_Single_1, source.Expression));
1788 }
1789
1790 [DynamicDependency("Average", typeof(Enumerable))]
1791 public static float? Average(this IQueryable<float?> source)
1792 {
1793 if (source == null)
1794 {
1795 throw Error.ArgumentNull("source");
1796 }
1797 return source.Provider.Execute<float?>(Expression.Call(null, CachedReflectionInfo.Average_NullableSingle_1, source.Expression));
1798 }
1799
1800 [DynamicDependency("Average", typeof(Enumerable))]
1801 public static double Average(this IQueryable<double> source)
1802 {
1803 if (source == null)
1804 {
1805 throw Error.ArgumentNull("source");
1806 }
1807 return source.Provider.Execute<double>(Expression.Call(null, CachedReflectionInfo.Average_Double_1, source.Expression));
1808 }
1809
1810 [DynamicDependency("Average", typeof(Enumerable))]
1811 public static double? Average(this IQueryable<double?> source)
1812 {
1813 if (source == null)
1814 {
1815 throw Error.ArgumentNull("source");
1816 }
1817 return source.Provider.Execute<double?>(Expression.Call(null, CachedReflectionInfo.Average_NullableDouble_1, source.Expression));
1818 }
1819
1820 [DynamicDependency("Average", typeof(Enumerable))]
1821 public static decimal Average(this IQueryable<decimal> source)
1822 {
1823 if (source == null)
1824 {
1825 throw Error.ArgumentNull("source");
1826 }
1827 return source.Provider.Execute<decimal>(Expression.Call(null, CachedReflectionInfo.Average_Decimal_1, source.Expression));
1828 }
1829
1830 [DynamicDependency("Average", typeof(Enumerable))]
1831 public static decimal? Average(this IQueryable<decimal?> source)
1832 {
1833 if (source == null)
1834 {
1835 throw Error.ArgumentNull("source");
1836 }
1837 return source.Provider.Execute<decimal?>(Expression.Call(null, CachedReflectionInfo.Average_NullableDecimal_1, source.Expression));
1838 }
1839
1840 [DynamicDependency("Average`1", typeof(Enumerable))]
1842 {
1843 if (source == null)
1844 {
1845 throw Error.ArgumentNull("source");
1846 }
1847 if (selector == null)
1848 {
1849 throw Error.ArgumentNull("selector");
1850 }
1851 return source.Provider.Execute<double>(Expression.Call(null, CachedReflectionInfo.Average_Int32_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(selector)));
1852 }
1853
1854 [DynamicDependency("Average`1", typeof(Enumerable))]
1856 {
1857 if (source == null)
1858 {
1859 throw Error.ArgumentNull("source");
1860 }
1861 if (selector == null)
1862 {
1863 throw Error.ArgumentNull("selector");
1864 }
1865 return source.Provider.Execute<double?>(Expression.Call(null, CachedReflectionInfo.Average_NullableInt32_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(selector)));
1866 }
1867
1868 [DynamicDependency("Average`1", typeof(Enumerable))]
1870 {
1871 if (source == null)
1872 {
1873 throw Error.ArgumentNull("source");
1874 }
1875 if (selector == null)
1876 {
1877 throw Error.ArgumentNull("selector");
1878 }
1879 return source.Provider.Execute<float>(Expression.Call(null, CachedReflectionInfo.Average_Single_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(selector)));
1880 }
1881
1882 [DynamicDependency("Average`1", typeof(Enumerable))]
1884 {
1885 if (source == null)
1886 {
1887 throw Error.ArgumentNull("source");
1888 }
1889 if (selector == null)
1890 {
1891 throw Error.ArgumentNull("selector");
1892 }
1893 return source.Provider.Execute<float?>(Expression.Call(null, CachedReflectionInfo.Average_NullableSingle_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(selector)));
1894 }
1895
1896 [DynamicDependency("Average`1", typeof(Enumerable))]
1898 {
1899 if (source == null)
1900 {
1901 throw Error.ArgumentNull("source");
1902 }
1903 if (selector == null)
1904 {
1905 throw Error.ArgumentNull("selector");
1906 }
1907 return source.Provider.Execute<double>(Expression.Call(null, CachedReflectionInfo.Average_Int64_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(selector)));
1908 }
1909
1910 [DynamicDependency("Average`1", typeof(Enumerable))]
1912 {
1913 if (source == null)
1914 {
1915 throw Error.ArgumentNull("source");
1916 }
1917 if (selector == null)
1918 {
1919 throw Error.ArgumentNull("selector");
1920 }
1921 return source.Provider.Execute<double?>(Expression.Call(null, CachedReflectionInfo.Average_NullableInt64_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(selector)));
1922 }
1923
1924 [DynamicDependency("Average`1", typeof(Enumerable))]
1926 {
1927 if (source == null)
1928 {
1929 throw Error.ArgumentNull("source");
1930 }
1931 if (selector == null)
1932 {
1933 throw Error.ArgumentNull("selector");
1934 }
1935 return source.Provider.Execute<double>(Expression.Call(null, CachedReflectionInfo.Average_Double_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(selector)));
1936 }
1937
1938 [DynamicDependency("Average`1", typeof(Enumerable))]
1940 {
1941 if (source == null)
1942 {
1943 throw Error.ArgumentNull("source");
1944 }
1945 if (selector == null)
1946 {
1947 throw Error.ArgumentNull("selector");
1948 }
1949 return source.Provider.Execute<double?>(Expression.Call(null, CachedReflectionInfo.Average_NullableDouble_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(selector)));
1950 }
1951
1952 [DynamicDependency("Average`1", typeof(Enumerable))]
1954 {
1955 if (source == null)
1956 {
1957 throw Error.ArgumentNull("source");
1958 }
1959 if (selector == null)
1960 {
1961 throw Error.ArgumentNull("selector");
1962 }
1963 return source.Provider.Execute<decimal>(Expression.Call(null, CachedReflectionInfo.Average_Decimal_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(selector)));
1964 }
1965
1966 [DynamicDependency("Average`1", typeof(Enumerable))]
1968 {
1969 if (source == null)
1970 {
1971 throw Error.ArgumentNull("source");
1972 }
1973 if (selector == null)
1974 {
1975 throw Error.ArgumentNull("selector");
1976 }
1977 return source.Provider.Execute<decimal?>(Expression.Call(null, CachedReflectionInfo.Average_NullableDecimal_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(selector)));
1978 }
1979
1980 [DynamicDependency("Aggregate`1", typeof(Enumerable))]
1982 {
1983 if (source == null)
1984 {
1985 throw Error.ArgumentNull("source");
1986 }
1987 if (func == null)
1988 {
1989 throw Error.ArgumentNull("func");
1990 }
1991 return source.Provider.Execute<TSource>(Expression.Call(null, CachedReflectionInfo.Aggregate_TSource_2(typeof(TSource)), source.Expression, Expression.Quote(func)));
1992 }
1993
1994 [DynamicDependency("Aggregate`2", typeof(Enumerable))]
1996 {
1997 if (source == null)
1998 {
1999 throw Error.ArgumentNull("source");
2000 }
2001 if (func == null)
2002 {
2003 throw Error.ArgumentNull("func");
2004 }
2006 }
2007
2008 [DynamicDependency("Aggregate`3", typeof(Enumerable))]
2010 {
2011 if (source == null)
2012 {
2013 throw Error.ArgumentNull("source");
2014 }
2015 if (func == null)
2016 {
2017 throw Error.ArgumentNull("func");
2018 }
2019 if (selector == null)
2020 {
2021 throw Error.ArgumentNull("selector");
2022 }
2024 }
2025
2026 [DynamicDependency("SkipLast`1", typeof(Enumerable))]
2028 {
2029 if (source == null)
2030 {
2031 throw Error.ArgumentNull("source");
2032 }
2033 return source.Provider.CreateQuery<TSource>(Expression.Call(null, CachedReflectionInfo.SkipLast_TSource_2(typeof(TSource)), source.Expression, Expression.Constant(count)));
2034 }
2035
2036 [DynamicDependency("TakeLast`1", typeof(Enumerable))]
2038 {
2039 if (source == null)
2040 {
2041 throw Error.ArgumentNull("source");
2042 }
2043 return source.Provider.CreateQuery<TSource>(Expression.Call(null, CachedReflectionInfo.TakeLast_TSource_2(typeof(TSource)), source.Expression, Expression.Constant(count)));
2044 }
2045
2046 [DynamicDependency("Append`1", typeof(Enumerable))]
2048 {
2049 if (source == null)
2050 {
2051 throw Error.ArgumentNull("source");
2052 }
2053 return source.Provider.CreateQuery<TSource>(Expression.Call(null, CachedReflectionInfo.Append_TSource_2(typeof(TSource)), source.Expression, Expression.Constant(element)));
2054 }
2055
2056 [DynamicDependency("Prepend`1", typeof(Enumerable))]
2058 {
2059 if (source == null)
2060 {
2061 throw Error.ArgumentNull("source");
2062 }
2063 return source.Provider.CreateQuery<TSource>(Expression.Call(null, CachedReflectionInfo.Prepend_TSource_2(typeof(TSource)), source.Expression, Expression.Constant(element)));
2064 }
2065}
static MethodInfo Average_NullableInt64_TSource_2(Type TSource)
static MethodInfo UnionBy_TSource_TKey_3(Type TSource, Type TKey)
static MethodInfo ExceptBy_TSource_TKey_4(Type TSource, Type TKey)
static MethodInfo Sum_Int64_TSource_2(Type TSource)
static MethodInfo GroupBy_TSource_TKey_TElement_4(Type TSource, Type TKey, Type TElement)
static MethodInfo First_TSource_1(Type TSource)
static MethodInfo Zip_TFirst_TSecond_TThird_3(Type TFirst, Type TSecond, Type TThird)
static MethodInfo Average_Single_TSource_2(Type TSource)
static MethodInfo Sum_NullableDouble_TSource_2(Type TSource)
static MethodInfo IntersectBy_TSource_TKey_3(Type TSource, Type TKey)
static MethodInfo Count_TSource_1(Type TSource)
static MethodInfo Single_TSource_2(Type TSource)
static MethodInfo LastOrDefault_TSource_2(Type TSource)
static MethodInfo Sum_Decimal_TSource_2(Type TSource)
static MethodInfo ElementAt_Index_TSource_2(Type TSource)
static MethodInfo Take_Range_TSource_2(Type TSource)
static MethodInfo Where_TSource_2(Type TSource)
static MethodInfo Sum_NullableSingle_TSource_2(Type TSource)
static MethodInfo FirstOrDefault_TSource_2(Type TSource)
static MethodInfo ElementAtOrDefault_Index_TSource_2(Type TSource)
static MethodInfo GroupBy_TSource_TKey_TResult_4(Type TSource, Type TKey, Type TResult)
static MethodInfo Average_NullableDecimal_TSource_2(Type TSource)
static MethodInfo Zip_TFirst_TSecond_TResult_3(Type TFirst, Type TSecond, Type TResult)
static MethodInfo FirstOrDefault_TSource_3(Type TSource)
static MethodInfo Append_TSource_2(Type TSource)
static MethodInfo Union_TSource_2(Type TSource)
static MethodInfo Except_TSource_3(Type TSource)
static MethodInfo Max_TSource_TResult_2(Type TSource, Type TResult)
static MethodInfo Join_TOuter_TInner_TKey_TResult_6(Type TOuter, Type TInner, Type TKey, Type TResult)
static MethodInfo Min_TSource_TResult_2(Type TSource, Type TResult)
static MethodInfo SkipWhile_Index_TSource_2(Type TSource)
static MethodInfo SequenceEqual_TSource_3(Type TSource)
static MethodInfo SingleOrDefault_TSource_4(Type TSource)
static MethodInfo GroupBy_TSource_TKey_TResult_3(Type TSource, Type TKey, Type TResult)
static MethodInfo FirstOrDefault_TSource_1(Type TSource)
static MethodInfo Except_TSource_2(Type TSource)
static MethodInfo All_TSource_2(Type TSource)
static MethodInfo Average_NullableDouble_TSource_2(Type TSource)
static MethodInfo ThenBy_TSource_TKey_2(Type TSource, Type TKey)
static MethodInfo Last_TSource_2(Type TSource)
static MethodInfo ElementAtOrDefault_Int32_TSource_2(Type TSource)
static MethodInfo GroupBy_TSource_TKey_TElement_3(Type TSource, Type TKey, Type TElement)
static MethodInfo Max_TSource_2(Type TSource)
static MethodInfo GroupBy_TSource_TKey_TElement_TResult_5(Type TSource, Type TKey, Type TElement, Type TResult)
static MethodInfo SelectMany_Index_TSource_TResult_2(Type TSource, Type TResult)
static MethodInfo Sum_Double_TSource_2(Type TSource)
static MethodInfo Select_Index_TSource_TResult_2(Type TSource, Type TResult)
static MethodInfo SingleOrDefault_TSource_2(Type TSource)
static MethodInfo First_TSource_2(Type TSource)
static MethodInfo DefaultIfEmpty_TSource_2(Type TSource)
static MethodInfo SkipLast_TSource_2(Type TSource)
static MethodInfo Min_TSource_2(Type TSource)
static MethodInfo ThenByDescending_TSource_TKey_2(Type TSource, Type TKey)
static MethodInfo GroupJoin_TOuter_TInner_TKey_TResult_6(Type TOuter, Type TInner, Type TKey, Type TResult)
static MethodInfo Select_TSource_TResult_2(Type TSource, Type TResult)
static MethodInfo UnionBy_TSource_TKey_4(Type TSource, Type TKey)
static MethodInfo GroupBy_TSource_TKey_3(Type TSource, Type TKey)
static MethodInfo Zip_TFirst_TSecond_2(Type TFirst, Type TSecond)
static MethodInfo ExceptBy_TSource_TKey_3(Type TSource, Type TKey)
static MethodInfo Contains_TSource_2(Type TSource)
static MethodInfo Average_Decimal_TSource_2(Type TSource)
static MethodInfo DistinctBy_TSource_TKey_2(Type TSource, Type TKey)
static MethodInfo OfType_TResult_1(Type TResult)
static MethodInfo Intersect_TSource_3(Type TSource)
static MethodInfo MinBy_TSource_TKey_3(Type TSource, Type TKey)
static MethodInfo OrderBy_TSource_TKey_2(Type TSource, Type TKey)
static MethodInfo ThenBy_TSource_TKey_3(Type TSource, Type TKey)
static MethodInfo Distinct_TSource_1(Type TSource)
static MethodInfo GroupJoin_TOuter_TInner_TKey_TResult_5(Type TOuter, Type TInner, Type TKey, Type TResult)
static MethodInfo OrderByDescending_TSource_TKey_2(Type TSource, Type TKey)
static MethodInfo ThenByDescending_TSource_TKey_3(Type TSource, Type TKey)
static MethodInfo Join_TOuter_TInner_TKey_TResult_5(Type TOuter, Type TInner, Type TKey, Type TResult)
static MethodInfo Take_Int32_TSource_2(Type TSource)
static MethodInfo Where_Index_TSource_2(Type TSource)
static MethodInfo Prepend_TSource_2(Type TSource)
static MethodInfo Min_TSource_1(Type TSource)
static MethodInfo Chunk_TSource_1(Type TSource)
static MethodInfo ElementAt_Int32_TSource_2(Type TSource)
static MethodInfo MaxBy_TSource_TKey_2(Type TSource, Type TKey)
static MethodInfo SingleOrDefault_TSource_3(Type TSource)
static MethodInfo Average_Int64_TSource_2(Type TSource)
static MethodInfo TakeLast_TSource_2(Type TSource)
static MethodInfo Reverse_TSource_1(Type TSource)
static MethodInfo LongCount_TSource_2(Type TSource)
static MethodInfo Count_TSource_2(Type TSource)
static MethodInfo Average_NullableInt32_TSource_2(Type TSource)
static MethodInfo MinBy_TSource_TKey_2(Type TSource, Type TKey)
static MethodInfo Intersect_TSource_2(Type TSource)
static MethodInfo DefaultIfEmpty_TSource_1(Type TSource)
static MethodInfo SelectMany_TSource_TResult_2(Type TSource, Type TResult)
static MethodInfo Distinct_TSource_2(Type TSource)
static MethodInfo IntersectBy_TSource_TKey_4(Type TSource, Type TKey)
static MethodInfo Last_TSource_1(Type TSource)
static MethodInfo Aggregate_TSource_TAccumulate_3(Type TSource, Type TAccumulate)
static MethodInfo Max_TSource_1(Type TSource)
static MethodInfo SequenceEqual_TSource_2(Type TSource)
static MethodInfo Aggregate_TSource_TAccumulate_TResult_4(Type TSource, Type TAccumulate, Type TResult)
static MethodInfo LastOrDefault_TSource_3(Type TSource)
static MethodInfo Skip_TSource_2(Type TSource)
static MethodInfo Aggregate_TSource_2(Type TSource)
static MethodInfo DistinctBy_TSource_TKey_3(Type TSource, Type TKey)
static MethodInfo SelectMany_TSource_TCollection_TResult_3(Type TSource, Type TCollection, Type TResult)
static MethodInfo Concat_TSource_2(Type TSource)
static MethodInfo Sum_Int32_TSource_2(Type TSource)
static MethodInfo SelectMany_Index_TSource_TCollection_TResult_3(Type TSource, Type TCollection, Type TResult)
static MethodInfo MaxBy_TSource_TKey_3(Type TSource, Type TKey)
static MethodInfo Contains_TSource_3(Type TSource)
static MethodInfo Cast_TResult_1(Type TResult)
static MethodInfo Average_NullableSingle_TSource_2(Type TSource)
static MethodInfo SkipWhile_TSource_2(Type TSource)
static MethodInfo GroupBy_TSource_TKey_TElement_TResult_4(Type TSource, Type TKey, Type TElement, Type TResult)
static MethodInfo Sum_Single_TSource_2(Type TSource)
static MethodInfo SingleOrDefault_TSource_1(Type TSource)
static MethodInfo LastOrDefault_TSource_1(Type TSource)
static MethodInfo Average_Double_TSource_2(Type TSource)
static MethodInfo LongCount_TSource_1(Type TSource)
static MethodInfo TakeWhile_Index_TSource_2(Type TSource)
static MethodInfo Sum_NullableDecimal_TSource_2(Type TSource)
static MethodInfo Sum_NullableInt32_TSource_2(Type TSource)
static MethodInfo TakeWhile_TSource_2(Type TSource)
static MethodInfo LastOrDefault_TSource_4(Type TSource)
static MethodInfo Single_TSource_1(Type TSource)
static MethodInfo OrderBy_TSource_TKey_3(Type TSource, Type TKey)
static MethodInfo Any_TSource_1(Type TSource)
static MethodInfo Sum_NullableInt64_TSource_2(Type TSource)
static MethodInfo FirstOrDefault_TSource_4(Type TSource)
static MethodInfo Average_Int32_TSource_2(Type TSource)
static MethodInfo Union_TSource_3(Type TSource)
static MethodInfo Any_TSource_2(Type TSource)
static MethodInfo OrderByDescending_TSource_TKey_3(Type TSource, Type TKey)
static MethodInfo GroupBy_TSource_TKey_2(Type TSource, Type TKey)
static IQueryable Create(Type elementType, IEnumerable sequence)
static Exception ArgumentOutOfRange(string message)
Definition Error.cs:20
static Exception ArgumentNull(string message)
Definition Error.cs:5
static Exception ArgumentNotIEnumerableGeneric(string message)
Definition Error.cs:10
static ConstantExpression Constant(object? value)
static MethodCallExpression Call(MethodInfo method)
static UnaryExpression Quote(Expression expression)
static ? TResult Min< TSource, TResult >(this IQueryable< TSource > source, Expression< Func< TSource, TResult > > selector)
static bool Any< TSource >(this IQueryable< TSource > source)
static IQueryable< TSource > SkipWhile< TSource >(this IQueryable< TSource > source, Expression< Func< TSource, bool > > predicate)
Definition Queryable.cs:463
static IQueryable< TResult > GroupJoin< TOuter, TInner, TKey, TResult >(this IQueryable< TOuter > outer, IEnumerable< TInner > inner, Expression< Func< TOuter, TKey > > outerKeySelector, Expression< Func< TInner, TKey > > innerKeySelector, Expression< Func< TOuter, IEnumerable< TInner >, TResult > > resultSelector)
Definition Queryable.cs:241
static IQueryable< TSource > UnionBy< TSource, TKey >(this IQueryable< TSource > source1, IEnumerable< TSource > source2, Expression< Func< TSource, TKey > > keySelector)
Definition Queryable.cs:785
static TSource Aggregate< TSource >(this IQueryable< TSource > source, Expression< Func< TSource, TSource, TSource > > func)
static double Average(this IQueryable< double > source)
static int Sum< TSource >(this IQueryable< TSource > source, Expression< Func< TSource, int > > selector)
static IOrderedQueryable< TSource > ThenByDescending< TSource, TKey >(this IOrderedQueryable< TSource > source, Expression< Func< TSource, TKey > > keySelector)
Definition Queryable.cs:377
static IQueryable< TSource[]> Chunk< TSource >(this IQueryable< TSource > source, int size)
Definition Queryable.cs:683
static ? TSource MaxBy< TSource, TKey >(this IQueryable< TSource > source, Expression< Func< TSource, TKey > > keySelector)
static IQueryable< TSource > Prepend< TSource >(this IQueryable< TSource > source, TSource element)
static IQueryable< TSource > TakeLast< TSource >(this IQueryable< TSource > source, int count)
static TResult Aggregate< TSource, TAccumulate, TResult >(this IQueryable< TSource > source, TAccumulate seed, Expression< Func< TAccumulate, TSource, TAccumulate > > func, Expression< Func< TAccumulate, TResult > > selector)
static IQueryable< TSource > DistinctBy< TSource, TKey >(this IQueryable< TSource > source, Expression< Func< TSource, TKey > > keySelector)
Definition Queryable.cs:655
static TSource ElementAt< TSource >(this IQueryable< TSource > source, int index)
static ? double Average(this IQueryable< double?> source)
static IQueryable< TResult > GroupBy< TSource, TKey, TResult >(this IQueryable< TSource > source, Expression< Func< TSource, TKey > > keySelector, Expression< Func< TKey, IEnumerable< TSource >, TResult > > resultSelector)
Definition Queryable.cs:577
static IQueryable< TSource > Intersect< TSource >(this IQueryable< TSource > source1, IEnumerable< TSource > source2)
Definition Queryable.cs:821
static IQueryable< TSource > Append< TSource >(this IQueryable< TSource > source, TSource element)
static IQueryable< TResult > GroupBy< TSource, TKey, TElement, TResult >(this IQueryable< TSource > source, Expression< Func< TSource, TKey > > keySelector, Expression< Func< TSource, TElement > > elementSelector, Expression< Func< TKey, IEnumerable< TElement >, TResult > > resultSelector)
Definition Queryable.cs:555
static IOrderedQueryable< TSource > OrderByDescending< TSource, TKey >(this IQueryable< TSource > source, Expression< Func< TSource, TKey > > keySelector)
Definition Queryable.cs:321
static ? TSource ElementAtOrDefault< TSource >(this IQueryable< TSource > source, int index)
static float Average(this IQueryable< float > source)
static ? float Average(this IQueryable< float?> source)
static IQueryable< TResult > SelectMany< TSource, TCollection, TResult >(this IQueryable< TSource > source, Expression< Func< TSource, int, IEnumerable< TCollection > > > collectionSelector, Expression< Func< TSource, TCollection, TResult > > resultSelector)
Definition Queryable.cs:144
static Expression GetSourceExpression< TSource >(IEnumerable< TSource > source)
Definition Queryable.cs:179
static IQueryable< TSource > IntersectBy< TSource, TKey >(this IQueryable< TSource > source1, IEnumerable< TKey > source2, Expression< Func< TSource, TKey > > keySelector)
Definition Queryable.cs:849
static IQueryable< TResult > OfType< TResult >(this IQueryable source)
Definition Queryable.cs:68
static bool SequenceEqual< TSource >(this IQueryable< TSource > source1, IEnumerable< TSource > source2)
static IQueryable< TSource > Union< TSource >(this IQueryable< TSource > source1, IEnumerable< TSource > source2)
Definition Queryable.cs:757
static IQueryable< TSource > Skip< TSource >(this IQueryable< TSource > source, int count)
Definition Queryable.cs:453
static ? TSource MinBy< TSource, TKey >(this IQueryable< TSource > source, Expression< Func< TSource, TKey > > keySelector)
static IQueryable< IGrouping< TKey, TElement > > GroupBy< TSource, TKey, TElement >(this IQueryable< TSource > source, Expression< Func< TSource, TKey > > keySelector, Expression< Func< TSource, TElement > > elementSelector)
Definition Queryable.cs:505
static ? double Sum(this IQueryable< double?> source)
static double Sum(this IQueryable< double > source)
static long LongCount< TSource >(this IQueryable< TSource > source)
static float Sum(this IQueryable< float > source)
static double Average< TSource >(this IQueryable< TSource > source, Expression< Func< TSource, int > > selector)
static bool Contains< TSource >(this IQueryable< TSource > source, TSource item)
static decimal Sum(this IQueryable< decimal > source)
static double Average(this IQueryable< long > source)
static IQueryable< TResult > Select< TSource, TResult >(this IQueryable< TSource > source, Expression< Func< TSource, TResult > > selector)
Definition Queryable.cs:88
static IQueryable< TSource > TakeWhile< TSource >(this IQueryable< TSource > source, Expression< Func< TSource, bool > > predicate)
Definition Queryable.cs:425
static IQueryable< TSource > Take< TSource >(this IQueryable< TSource > source, int count)
Definition Queryable.cs:405
static ? TResult Max< TSource, TResult >(this IQueryable< TSource > source, Expression< Func< TSource, TResult > > selector)
static IQueryable AsQueryable(this IEnumerable source)
Definition Queryable.cs:21
static ? long Sum(this IQueryable< long?> source)
static ? TSource FirstOrDefault< TSource >(this IQueryable< TSource > source)
Definition Queryable.cs:973
static ? TSource LastOrDefault< TSource >(this IQueryable< TSource > source)
static IQueryable< TSource > SkipLast< TSource >(this IQueryable< TSource > source, int count)
static ? int Sum(this IQueryable< int?> source)
static TSource Last< TSource >(this IQueryable< TSource > source)
static TAccumulate Aggregate< TSource, TAccumulate >(this IQueryable< TSource > source, TAccumulate seed, Expression< Func< TAccumulate, TSource, TAccumulate > > func)
static ? TSource Min< TSource >(this IQueryable< TSource > source)
static IQueryable< TSource > Reverse< TSource >(this IQueryable< TSource > source)
static IQueryable< TResult > Zip< TFirst, TSecond, TResult >(this IQueryable< TFirst > source1, IEnumerable< TSecond > source2, Expression< Func< TFirst, TSecond, TResult > > resultSelector)
Definition Queryable.cs:721
static int Sum(this IQueryable< int > source)
static TSource First< TSource >(this IQueryable< TSource > source)
Definition Queryable.cs:949
static ? decimal Sum(this IQueryable< decimal?> source)
static IQueryable< TResult > Cast< TResult >(this IQueryable source)
Definition Queryable.cs:78
static ? double Average(this IQueryable< int?> source)
static IOrderedQueryable< TSource > ThenBy< TSource, TKey >(this IOrderedQueryable< TSource > source, Expression< Func< TSource, TKey > > keySelector)
Definition Queryable.cs:349
static IQueryable< TSource > Concat< TSource >(this IQueryable< TSource > source1, IEnumerable< TSource > source2)
Definition Queryable.cs:693
static IQueryable< TSource > Distinct< TSource >(this IQueryable< TSource > source)
Definition Queryable.cs:635
static ? double Average(this IQueryable< long?> source)
static IQueryable< TResult > SelectMany< TSource, TResult >(this IQueryable< TSource > source, Expression< Func< TSource, IEnumerable< TResult > > > selector)
Definition Queryable.cs:116
static bool All< TSource >(this IQueryable< TSource > source, Expression< Func< TSource, bool > > predicate)
static ? TSource Max< TSource >(this IQueryable< TSource > source)
static IQueryable< TElement > AsQueryable< TElement >(this IEnumerable< TElement > source)
Definition Queryable.cs:11
static IQueryable< IGrouping< TKey, TSource > > GroupBy< TSource, TKey >(this IQueryable< TSource > source, Expression< Func< TSource, TKey > > keySelector)
Definition Queryable.cs:491
static int Count< TSource >(this IQueryable< TSource > source)
static TSource Single< TSource >(this IQueryable< TSource > source)
static IQueryable< TSource > ExceptBy< TSource, TKey >(this IQueryable< TSource > source1, IEnumerable< TKey > source2, Expression< Func< TSource, TKey > > keySelector)
Definition Queryable.cs:913
static IQueryable< TSource > DefaultIfEmpty< TSource >(this IQueryable< TSource > source)
static IQueryable< TSource > Except< TSource >(this IQueryable< TSource > source1, IEnumerable< TSource > source2)
Definition Queryable.cs:885
static IOrderedQueryable< TSource > OrderBy< TSource, TKey >(this IQueryable< TSource > source, Expression< Func< TSource, TKey > > keySelector)
Definition Queryable.cs:293
static IQueryable< TSource > Where< TSource >(this IQueryable< TSource > source, Expression< Func< TSource, bool > > predicate)
Definition Queryable.cs:40
static ? decimal Average(this IQueryable< decimal?> source)
static long Sum(this IQueryable< long > source)
static IQueryable< TResult > Join< TOuter, TInner, TKey, TResult >(this IQueryable< TOuter > outer, IEnumerable< TInner > inner, Expression< Func< TOuter, TKey > > outerKeySelector, Expression< Func< TInner, TKey > > innerKeySelector, Expression< Func< TOuter, TInner, TResult > > resultSelector)
Definition Queryable.cs:189
static decimal Average(this IQueryable< decimal > source)
static double Average(this IQueryable< int > source)
static ? TSource SingleOrDefault< TSource >(this IQueryable< TSource > source)
static ? float Sum(this IQueryable< float?> source)
static Type FindGenericType(Type definition, Type type)
Definition TypeHelper.cs:8