예제 #1
0
        public Dataset <T> Transform(Func <T, T> fn, bool lazy = true)
        {
            var trans = new _LazyTransformDataset <T>(this, fn);

            if (lazy)
            {
                return(trans);
            }

            return(new SimpleDataset <T>(trans.Data.ToArray()));
        }
예제 #2
0
        private Dataset <T> Transform(_TransformFirstClosure fn, bool lazy = true)
        {
            var trans = new _LazyTransformDataset <T>(this, fn);

            if (lazy)
            {
                return(trans);
            }

            return(new SimpleDataset <T>(trans.Data.ToArray()));
        }