示例#1
0
        public static Operation <T> Select <T>(this Operation operation, Func <object, T> process)
        {
            var op1 = new Operation <object>(operation.GetException())
            {
                Message   = operation.Message,
                Result    = null,
                Succeeded = operation.Succeeded
            };

            return(OperationExtensions.Next(op1, process));
        }
示例#2
0
 public static Operation <U> Select <T, U>(this Operation <T> operation, Func <T, U> process)
 {
     return(OperationExtensions.Next(operation, process));
 }
示例#3
0
 public static IEnumerable <Operation <V> > SelectMany <T, U, V>(this IEnumerable <T> operation, Func <T, Operation <U> > process, Func <T, U, V> projection)
 {
     return(operation.Select(x => OperationExtensions.Next(process(x), u => projection(x, u))));
 }