예제 #1
0
        public static void Test(IFilter filter, string input, string output)
        {
            Bitmap bitmap = new Bitmap(input);

            bitmap = filter.ApplyTo(bitmap);

            bitmap.Save(output);
        }
예제 #2
0
 public static IEnumerable <T> ApplyTo <T>(this IFilter <T> me, IEnumerable <T> source)
 => me.ApplyTo(source.AsQueryable());
예제 #3
0
 public static IQueryable <T> ApplyTo <T>(this IFilter <T> me, Func <IQueryable <T> > source)
 => me.ApplyTo(source());
        public static IQueryable <T> Filter <T> (this IQueryable <T> source, [NotNull] IFilter <T>?filter)
        {
            ThrowHelper.ThrowIfIsNull(filter, nameof(filter));

            return(filter.ApplyTo(source));
        }
예제 #5
0
 public static Bitmap Apply(this SmartBitmap image, IFilter filter)
 {
     return filter.ApplyTo(image);
 }