for TARGET_J2EE only:
[mono.git] / mcs / class / System.Core / System.Linq / Queryable.cs
1 //
2 // Queryable.cs
3 //
4 // Authors:
5 //  Marek Safar (marek.safar@gmail.com)
6 //  Alejandro Serrano "Serras" (trupill@yahoo.es)
7 //  Jb Evain (jbevain@novell.com)
8 //
9 // Copyright (C) 2007 Novell, Inc (http://www.novell.com)
10 //
11 // Permission is hereby granted, free of charge, to any person obtaining
12 // a copy of this software and associated documentation files (the
13 // "Software"), to deal in the Software without restriction, including
14 // without limitation the rights to use, copy, modify, merge, publish,
15 // distribute, sublicense, and/or sell copies of the Software, and to
16 // permit persons to whom the Software is furnished to do so, subject to
17 // the following conditions:
18 //
19 // The above copyright notice and this permission notice shall be
20 // included in all copies or substantial portions of the Software.
21 //
22 // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
23 // EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
24 // MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
25 // NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
26 // LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
27 // OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
28 // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
29 //
30
31 using System;
32 using System.Collections.Generic;
33 using System.Linq.Expressions;
34 using System.Reflection;
35
36 namespace System.Linq {
37
38         public static class Queryable {
39
40                 static MethodInfo MakeGeneric (MethodBase method, params Type [] parameters)
41                 {
42                         return ((MethodInfo) method).MakeGenericMethod (parameters);
43                 }
44
45                 static Expression StaticCall (MethodInfo method, params Expression [] expressions)
46                 {
47                         return Expression.Call (null, method, expressions);
48                 }
49
50                 static TRet Execute<TRet, TSource> (this IQueryable<TSource> source, MethodBase current)
51                 {
52                         return source.Provider.Execute<TRet> (
53                                 StaticCall (
54                                         MakeGeneric (current, typeof (TSource)),
55                                         source.Expression));
56                 }
57
58                 public static int Count<TSource> (this IQueryable<TSource> source)
59                 {
60                         Check.Source (source);
61
62                         return source.Execute<int, TSource> (MethodBase.GetCurrentMethod ());
63                 }
64
65                 public static int Count<TSource> (this IQueryable<TSource> source, Expression<Func<TSource, bool>> predicate)
66                 {
67                         Check.SourceAndPredicate (source, predicate);
68
69                         return source.Provider.Execute<int> (
70                                 StaticCall (
71                                         MakeGeneric (MethodBase.GetCurrentMethod (), typeof (TSource)),
72                                         source.Expression,
73                                         Expression.Quote (predicate)));
74                 }
75
76                 public static long LongCount<TSource> (this IQueryable<TSource> source)
77                 {
78                         Check.Source (source);
79
80                         return source.Execute<long, TSource> (MethodBase.GetCurrentMethod ());
81                 }
82
83                 public static long LongCount<TSource> (this IQueryable<TSource> source, Expression<Func<TSource, bool>> predicate)
84                 {
85                         Check.SourceAndPredicate (source, predicate);
86
87                         return source.Provider.Execute<long> (
88                                 StaticCall (
89                                         MakeGeneric (MethodBase.GetCurrentMethod (), typeof (TSource)),
90                                         source.Expression,
91                                         Expression.Quote (predicate)));
92                 }
93
94                 public static int Sum (this IQueryable<int> source)
95                 {
96                         Check.Source (source);
97
98                         return source.Provider.Execute<int> (
99                                 StaticCall (
100                                         (MethodInfo) MethodBase.GetCurrentMethod (),
101                                         source.Expression));
102                 }
103                 
104                 public static int Sum<TSource> (this IQueryable<TSource> source, Expression<Func<TSource, int>> selector)
105                 {
106                         throw new NotImplementedException ();
107                 }
108                 
109                 public static int? Sum (this IQueryable<int?> source)
110                 {
111                         throw new NotImplementedException ();
112                 }
113                 
114                 public static int? Sum<TSource> (
115                         this IQueryable<TSource> source,
116                         Func<TSource, int?> selector)
117                 {
118                         throw new NotImplementedException ();
119                 }
120
121                 public static long Sum (this IQueryable<long> source)
122                 {
123                         throw new NotImplementedException ();
124                 }
125                 
126                 public static long Sum<TSource> (
127                         this IQueryable<TSource> source,
128                         Func<TSource, long> selector)
129                 {
130                         throw new NotImplementedException ();
131                 }
132                 
133                 public static long? Sum (this IQueryable<long?> source)
134                 {
135                         throw new NotImplementedException ();
136                 }
137                 
138                 public static long? Sum<TSource> (
139                         this IQueryable<TSource> source,
140                         Func<TSource, long?> selector)
141                 {
142                         throw new NotImplementedException ();
143                 }
144                 
145                 public static double Sum (this IQueryable<double> source)
146                 {
147                         throw new NotImplementedException ();
148                 }
149                 
150                 public static double Sum<TSource> (
151                         this IQueryable<TSource> source,
152                         Func<TSource, double> selector)
153                 {
154                         throw new NotImplementedException ();
155                 }
156                 
157                 public static double? Sum (this IQueryable<double?> source)
158                 {
159                         throw new NotImplementedException ();
160                 }
161                 
162                 public static double? Sum<TSource> (
163                         this IQueryable<TSource> source,
164                         Func<TSource, double?> selector)
165                 {
166                         throw new NotImplementedException ();
167                 }
168                 
169                 public static decimal Sum (this IQueryable<decimal> source)
170                 {
171                         throw new NotImplementedException ();
172                 }
173                 
174                 public static decimal Sum<TSource> (
175                         this IQueryable<TSource> source,
176                         Func<TSource, decimal> selector)
177                 {
178                         throw new NotImplementedException ();
179                 }
180
181                 public static decimal? Sum (this IQueryable<decimal?> source)
182                 {
183                         throw new NotImplementedException ();
184                 }
185
186                 public static decimal? Sum<TSource> (
187                         this IQueryable<TSource> source,
188                         Func<TSource, decimal?> selector)
189                 {
190                         throw new NotImplementedException ();
191                 }
192
193                 public static int Min (this IQueryable<int> source)
194                 {
195                         throw new NotImplementedException ();
196                 }
197                 
198                 public static int? Min (this IQueryable<int?> source)
199                 {
200                         throw new NotImplementedException ();
201                 }
202                 
203                 public static long Min (this IQueryable<long> source)
204                 {
205                         throw new NotImplementedException ();
206                 }
207                 
208                 public static long? Min (this IQueryable<long?> source)
209                 {
210                         throw new NotImplementedException ();
211                 }
212                 
213                 public static double Min (this IQueryable<double> source)
214                 {
215                         throw new NotImplementedException ();
216                 }
217                 
218                 public static double? Min (this IQueryable<double?> source)
219                 {
220                         throw new NotImplementedException ();
221                 }
222                 
223                 public static decimal Min (this IQueryable<decimal> source)
224                 {
225                         throw new NotImplementedException ();
226                 }
227                 
228                 public static decimal? Min (this IQueryable<decimal?> source)
229                 {
230                         throw new NotImplementedException ();
231                 }
232                 
233                 public static TSource Min<TSource> (this IQueryable<TSource> source)
234                 {
235                         throw new NotImplementedException ();
236                 }
237                 
238                 public static int Min<TSource> (
239                         this IQueryable<TSource> source,
240                         Func<TSource, int> selector)
241                 {
242                         throw new NotImplementedException ();
243                 }
244                 
245                 public static int? Min<TSource> (
246                         this IQueryable<TSource> source,
247                         Func<TSource, int?> selector)
248                 {
249                         throw new NotImplementedException ();
250                 }
251                 
252                 public static long Min<TSource> (
253                         this IQueryable<TSource> source,
254                         Func<TSource, long> selector)
255                 {
256                         throw new NotImplementedException ();
257                 }
258                 
259                 public static long? Min<TSource> (
260                         this IQueryable<TSource> source,
261                         Func<TSource, long?> selector)
262                 {
263                         throw new NotImplementedException ();
264                 }
265                 
266                 public static double Min<TSource> (
267                         this IQueryable<TSource> source,
268                         Func<TSource, double> selector)
269                 {
270                         throw new NotImplementedException ();
271                 }
272                 
273                 public static double? Min<TSource> (
274                         this IQueryable<TSource> source,
275                         Func<TSource, double?> selector)
276                 {
277                         throw new NotImplementedException ();
278                 }
279                 
280                 public static decimal Min<TSource> (
281                         this IQueryable<TSource> source,
282                         Func<TSource, decimal> selector)
283                 {
284                         throw new NotImplementedException ();
285                 }
286                 
287                 public static decimal? Min<TSource> (
288                         this IQueryable<TSource> source,
289                         Func<TSource, decimal?> selector)
290                 {
291                         throw new NotImplementedException ();
292                 }
293                 
294                 public static TResult Min<TSource, TResult> (
295                         this IQueryable<TSource> source,
296                         Func<TSource, TResult> selector)
297                 {
298                         throw new NotImplementedException ();
299                 }
300                 
301                 public static int Max (this IQueryable<int> source)
302                 {
303                         throw new NotImplementedException ();
304                 }
305                 
306                 public static int? Max (this IQueryable<int?> source)
307                 {
308                         throw new NotImplementedException ();
309                 }
310                 
311                 public static long Max (this IQueryable<long> source)
312                 {
313                         throw new NotImplementedException ();
314                 }
315                 
316                 public static long? Max (this IQueryable<long?> source)
317                 {
318                         throw new NotImplementedException ();
319                 }
320                 
321                 public static double Max (
322                         this IQueryable<double> source)
323                 {
324                         throw new NotImplementedException ();
325                 }
326                 
327                 public static double? Max (
328                         this IQueryable<double?> source)
329                 {
330                         throw new NotImplementedException ();
331                 }
332                 
333                 public static decimal Max (
334                         this IQueryable<decimal> source)
335                 {
336                         throw new NotImplementedException ();
337                 }
338                 
339                 public static decimal? Max (
340                         this IQueryable<decimal?> source)
341                 {
342                         throw new NotImplementedException ();
343                 }
344                 
345                 public static TSource Max<TSource> (
346                         this IQueryable<TSource> source)
347                 {
348                         throw new NotImplementedException ();
349                 }
350                 
351                 public static int Max<TSource> (
352                         this IQueryable<TSource> source,
353                         Func<TSource, int> selector)
354                 {
355                         throw new NotImplementedException ();
356                 }
357                 
358                 public static int? Max<TSource> (
359                         this IQueryable<TSource> source,
360                         Func<TSource, int?> selector)
361                 {
362                         throw new NotImplementedException ();
363                 }
364                 
365                 public static long Max<TSource> (
366                         this IQueryable<TSource> source,
367                         Func<TSource, long> selector)
368                 {
369                         throw new NotImplementedException ();
370                 }
371                 
372                 public static long? Max<TSource> (
373                         this IQueryable<TSource> source,
374                         Func<TSource, long?> selector)
375                 {
376                         throw new NotImplementedException ();
377                 }
378                 
379                 public static double Max<TSource> (
380                         this IQueryable<TSource> source,
381                         Func<TSource, double> selector)
382                 {
383                         throw new NotImplementedException ();
384                 }
385                 
386                 public static double? Max<TSource> (
387                         this IQueryable<TSource> source,
388                         Func<TSource, double?> selector)
389                 {
390                         throw new NotImplementedException ();
391                 }
392                 
393                 public static decimal Max<TSource> (
394                         this IQueryable<TSource> source,
395                         Func<TSource, decimal> selector)
396                 {
397                         throw new NotImplementedException ();
398                 }
399                 
400                 public static decimal? Max<TSource> (
401                         this IQueryable<TSource> source,
402                         Func<TSource, decimal?> selector)
403                 {
404                         throw new NotImplementedException ();
405                 }
406                 
407                 public static TResult Max<TSource, TResult> (
408                         this IQueryable<TSource> source,
409                         Func<TSource, TResult> selector)
410                 {
411                         throw new NotImplementedException ();
412                 }
413                                 
414                 public static double Average (this IQueryable<int> source)
415                 {
416                         throw new NotImplementedException ();
417                 }
418                 
419                 public static double? Average (this IQueryable<int?> source)
420                 {
421                         throw new NotImplementedException ();
422                 }
423                 
424                 public static double Average (this IQueryable<long> source)
425                 {
426                         throw new NotImplementedException ();
427                 }
428                 
429                 public static double? Average (this IQueryable<long?> source)
430                 {
431                         throw new NotImplementedException ();
432                 }
433                 
434                 public static double Average (this IQueryable<double> source)
435                 {
436                         throw new NotImplementedException ();
437                 }
438                 
439                 public static double? Average (this IQueryable<double?> source)
440                 {
441                         throw new NotImplementedException ();
442                 }
443                 
444                 public static decimal Average (this IQueryable<decimal> source)
445                 {
446                         throw new NotImplementedException ();
447                 }
448                 
449                 public static decimal? Average (this IQueryable<decimal?> source)
450                 {
451                         throw new NotImplementedException ();
452                 }
453                 
454                 public static double Average<TSource> (this IQueryable<TSource> source,
455                         Func<TSource, int> selector)
456                 {
457                         throw new NotImplementedException ();
458                 }
459                 
460                 public static double? Average<TSource> (this IQueryable<TSource> source,
461                         Func<TSource, int?> selector)
462                 {
463                         throw new NotImplementedException ();
464                 }
465                 
466                 public static double Average<TSource> (this IQueryable<TSource> source,
467                         Func<TSource, long> selector)
468                 {
469                         throw new NotImplementedException ();
470                 }
471                 
472                 public static double? Average<TSource> (this IQueryable<TSource> source,
473                         Func<TSource, long?> selector)
474                 {
475                         throw new NotImplementedException ();
476                 }
477                 
478                 public static double Average<TSource> (this IQueryable<TSource> source,
479                         Func<TSource, double> selector)
480                 {
481                         throw new NotImplementedException ();
482                 }
483                 
484                 public static double? Average<TSource> (this IQueryable<TSource> source,
485                         Func<TSource, double?> selector)
486                 {
487                         throw new NotImplementedException ();
488                 }
489                 
490                 public static decimal Average<TSource> (this IQueryable<TSource> source,
491                         Func<TSource, decimal> selector)
492                 {
493                         throw new NotImplementedException ();
494                 }
495                 
496                 public static decimal? Average<TSource> (this IQueryable<TSource> source,
497                         Func<TSource, decimal?> selector)
498                 {
499                         throw new NotImplementedException ();
500                 }
501                 
502                 public static TSource Aggregate<TSource> (
503                         this IQueryable<TSource> source,
504                         Func<TSource, TSource, TSource> func)
505                 {
506                         throw new NotImplementedException ();
507                 }
508                 
509                 public static U Aggregate<TSource, U> (
510                         this IQueryable<TSource> source,
511                         U seed,
512                         Func<U, TSource, U> func)
513                 {
514                         throw new NotImplementedException ();
515                 }
516
517                 public static IEnumerable<TSource> Concat<TSource> (
518                         this IQueryable<TSource> first,
519                         IEnumerable<TSource> second)
520                 {
521                         throw new NotImplementedException ();
522                 }
523                 
524                 public static IEnumerable<TResult> OfType<TResult> (this IQueryable source)
525                 {
526                         throw new NotImplementedException ();
527                 }               
528
529                 public static IEnumerable<TResult> Cast<TResult> (this IQueryable source)
530                 {
531                         throw new NotImplementedException ();
532                 }
533                 
534                 public static TSource First<TSource> (this IQueryable<TSource> source)
535                 {
536                         throw new NotImplementedException ();
537                 }
538                 
539                 public static TSource First<TSource> (
540                         this IQueryable<TSource> source,
541                         Func<TSource, bool> predicate)
542                 {
543                         throw new NotImplementedException ();
544                 }
545                 
546                 public static TSource FirstOrDefault<TSource> (this IQueryable<TSource> source)
547                 {
548                         throw new NotImplementedException ();
549                 }
550                 
551                 public static TSource FirstOrDefault<TSource> (
552                         this IQueryable<TSource> source,
553                         Func<TSource, bool> predicate)
554                 {
555                         throw new NotImplementedException ();
556                 }
557                 
558                 public static TSource Last<TSource> (this IQueryable<TSource> source)
559                 {
560                         throw new NotImplementedException ();
561                 }
562                 
563                 public static TSource Last<TSource> (
564                         this IQueryable<TSource> source,
565                         Func<TSource, bool> predicate)
566                 {
567                         throw new NotImplementedException ();
568                 }
569                 
570                 public static TSource LastOrDefault<TSource> (this IQueryable<TSource> source)
571                 {
572                         throw new NotImplementedException ();
573                 }
574                 
575                 public static TSource LastOrDefault<TSource> (
576                         this IQueryable<TSource> source,
577                         Func<TSource, bool> predicate)
578                 {
579                         throw new NotImplementedException ();
580                 }
581                 
582                 public static TSource Single<TSource> (this IQueryable<TSource> source)
583                 {
584                         throw new NotImplementedException ();
585                 }
586                 
587                 public static TSource Single<TSource> (
588                         this IQueryable<TSource> source,
589                         Func<TSource, bool> predicate)
590                 {
591                         throw new NotImplementedException ();
592                 }
593                 
594                 public static TSource SingleOrDefault<TSource> (this IQueryable<TSource> source)
595                 {
596                         throw new NotImplementedException ();
597                 }
598                 
599                 public static TSource SingleOrDefault<TSource> (
600                         this IQueryable<TSource> source,
601                         Func<TSource, bool> predicate)
602                 {
603                         throw new NotImplementedException ();
604                 }
605                 
606                 public static TSource ElementAt<TSource> (
607                         this IQueryable<TSource> source,
608                         int index)
609                 {
610                         throw new NotImplementedException ();
611                 }
612                 
613                 public static TSource ElementAtOrDefault<TSource> (
614                         this IQueryable<TSource> source,
615                         int index)
616                 {
617                         throw new NotImplementedException ();
618                 }
619                 
620                 public static IEnumerable<TSource> DefaultIfEmpty<TSource> (
621                         this IQueryable<TSource> source)
622                 {
623                         throw new NotImplementedException ();
624                 }
625                 
626                 public static IEnumerable<TSource> DefaultIfEmpty<TSource> (
627                         this IQueryable<TSource> source,
628                         TSource defaultValue)
629                 {
630                         throw new NotImplementedException ();
631                 }
632
633                 public static IEnumerable<TSource> Repeat<TSource> (this TSource element, int count)
634                 {
635                         throw new NotImplementedException ();
636                 }
637                 
638                 private static List<TSource> ContainsGroup<K, TSource>(
639                         Dictionary<K, List<TSource>> items, K key, IEqualityComparer<K> comparer)
640                 {
641                         throw new NotImplementedException ();
642                 }
643                 
644                 public static IQueryable<IGrouping<K, TSource>> GroupBy<TSource, K> (
645                         this IQueryable<TSource> source,
646                         Func<TSource, K> keySelector)
647                 {
648                         throw new NotImplementedException ();
649                 }
650
651                 public static IQueryable<IGrouping<K, E>> GroupBy<TSource, K, E> (
652                         this IQueryable<TSource> source,
653                         Func<TSource, K> keySelector,
654                         Func<TSource, E> elementSelector)
655                 {
656                         throw new NotImplementedException ();
657                 }
658                 
659                 public static IEnumerable<IGrouping<K, E>> GroupBy<TSource, K, E> (
660                         this IQueryable<TSource> source,
661                         Func<TSource, K> keySelector,
662                         Func<TSource, E> elementSelector,
663                         IEqualityComparer<K> comparer)
664                 {
665                         throw new NotImplementedException ();
666                 }
667                 
668                 public static IOrderedQueryable<TSource> OrderBy<TSource, TKey> (
669                         this IQueryable<TSource> source,
670                         Func<TSource, TKey> keySelector)
671                 {
672                         throw new NotImplementedException ();
673                 }
674                 
675                 public static IOrderedQueryable<TSource> OrderBy<TSource, TKey> (
676                         this IQueryable<TSource> source,
677                         Func<TSource, TKey> keySelector,
678                         IComparer<TKey> comparer)
679                 {
680                         throw new NotImplementedException ();
681                 }
682                 
683                 public static IOrderedQueryable<TSource> OrderByDescending<TSource, TKey> (
684                         this IQueryable<TSource> source,
685                         Func<TSource, TKey> keySelector)
686                 {
687                         throw new NotImplementedException ();
688                 }
689                 
690                 public static IOrderedQueryable<TSource> OrderByDescending<TSource, TKey> (
691                         this IQueryable<TSource> source,
692                         Func<TSource, TKey> keySelector,
693                         IComparer<TKey> comparer)
694                 {
695                         throw new NotImplementedException ();
696                 }
697
698                 public static IOrderedQueryable<TSource> ThenBy<TSource, TKey> (
699                         this IOrderedQueryable<TSource> source,
700                         Func<TSource, TKey> keySelector)
701                 {
702                         throw new NotImplementedException ();
703                 }
704                 
705                 public static IOrderedQueryable<TSource> ThenBy<TSource, TKey> (
706                         this IOrderedQueryable<TSource> source,
707                         Func<TSource, TKey> keySelector,
708                         IComparer<TKey> comparer)
709                 {
710                         throw new NotImplementedException ();
711                 }
712                 
713                 public static IOrderedQueryable<TSource> ThenByDescending<TSource, TKey> (
714                         this IOrderedQueryable<TSource> source,
715                         Func<TSource, TKey> keySelector)
716                 {
717                         throw new NotImplementedException ();
718                 }
719                 
720                 public static IOrderedQueryable<TSource> ThenByDescending<TSource, TKey> (
721                         this IOrderedQueryable<TSource> source,
722                         Func<TSource, TKey> keySelector,
723                         IComparer<TKey> comparer)
724                 {
725                         throw new NotImplementedException ();
726                 }
727
728                 public static IQueryable<TSource> Reverse<TSource> (
729                         this IQueryable<TSource> source)
730                 {
731                         throw new NotImplementedException ();
732                 }
733                 
734                 public static IEnumerable<TSource> Take<TSource> (
735                         this IQueryable<TSource> source,
736                         int count)
737                 {
738                         throw new NotImplementedException ();
739                 }
740                 
741                 public static IEnumerable<TSource> Skip<TSource> (
742                         this IQueryable<TSource> source,
743                         int count)
744                 {
745                         throw new NotImplementedException ();
746                 }
747
748                 public static IEnumerable<TSource> TakeWhile<TSource> (
749                         this IQueryable<TSource> source,
750                         Func<TSource, bool> predicate)
751                 {
752                         throw new NotImplementedException ();
753                 }
754                 
755                 public static IEnumerable<TSource> TakeWhile<TSource> (
756                         this IQueryable<TSource> source,
757                         Func<TSource, int, bool> predicate)
758                 {
759                         throw new NotImplementedException ();
760                 }
761                 
762                 public static IEnumerable<TSource> SkipWhile<TSource> (
763                         this IQueryable<TSource> source,
764                         Func<TSource, bool> predicate)
765                 {
766                         throw new NotImplementedException ();
767                 }
768                 
769                 public static IEnumerable<TSource> SkipWhile<TSource> (
770                         this IQueryable<TSource> source,
771                         Func<TSource, int, bool> predicate)
772                 {
773                         throw new NotImplementedException ();
774                 }
775                 
776                 public static IEnumerable<TResult> Select<TSource, TResult> (
777                         this IQueryable<TSource> source,
778                         Func<TSource, TResult> selector)
779                 {
780                         throw new NotImplementedException ();
781                 }
782                 
783                 public static IEnumerable<TResult> Select<TSource, TResult> (
784                         this IQueryable<TSource> source,
785                         Func<TSource, int, TResult> selector)
786                 {
787                         throw new NotImplementedException ();
788                 }
789                 
790                 public static IEnumerable<TResult> SelectMany<TSource, TResult> (
791                         this IQueryable<TSource> source,
792                         Func<TSource, IQueryable<TResult>> selector)
793                 {
794                         throw new NotImplementedException ();
795                 }
796                 
797                 public static IEnumerable<TResult> SelectMany<TSource, TResult> (
798                         this IQueryable<TSource> source,
799                         Func<TSource, int, IQueryable<TResult>> selector)
800                 {
801                         throw new NotImplementedException ();
802                 }
803                 
804                 public static bool Any<TSource> (this IQueryable<TSource> source)
805                 {
806                         throw new NotImplementedException ();
807                 }
808                 
809                 public static bool Any<TSource> (
810                         this IQueryable<TSource> source,
811                         Func<TSource, bool> predicate)
812                 {
813                         throw new NotImplementedException ();
814                 }
815                 
816                 public static bool All<TSource> (
817                         this IQueryable<TSource> source,
818                         Func<TSource, bool> predicate)
819                 {
820                         throw new NotImplementedException ();
821                 }
822                 
823                 public static bool Contains<TSource> (this IQueryable<TSource> source, TSource value)
824                 {
825                         throw new NotImplementedException ();
826                 }
827                 
828                 public static IEnumerable<TSource> Where<TSource> (
829                         this IQueryable<TSource> source,
830                         Func<TSource, bool> predicate)
831                 {
832                         throw new NotImplementedException ();
833                 }
834                 
835                 public static IEnumerable<TSource> Where<TSource> (
836                         this IQueryable<TSource> source,
837                         Func<TSource, int, bool> predicate)
838                 {
839                         throw new NotImplementedException ();
840                 }
841                 
842                 public static IEnumerable<V> Join<TSource, U, K, V> (
843                         this IQueryable<TSource> outer,
844                         IQueryable<U> inner,
845                         Func<TSource, K> outerKeySelector,
846                         Func<U, K> innerKeySelector,
847                         Func<TSource, U, V> resultSelector)
848                 {                       
849                         throw new NotImplementedException ();
850                 }
851         }
852 }