示例#1
0
文件: MaybeTC.cs 项目: forki/Funcy
 public MaybeTC <TReturn> Apply <TReturn>(MaybeTC <Func <T, TReturn> > f)
 {
     if (f.IsSome)
     {
         return(this.FMap <TReturn>(f.ToSome().Value));
     }
     else
     {
         return(MaybeTC.None <TReturn>());
     }
 }
示例#2
0
文件: MaybeTC.cs 项目: forki/Funcy
 public MaybeTC <TReturn> ApplyRight <TReturn>(MaybeTC <TReturn> other)
 {
     return(other);
 }
示例#3
0
文件: MaybeTC.cs 项目: forki/Funcy
 public MaybeTC <T> ApplyLeft <TReturn>(MaybeTC <TReturn> other)
 {
     return(this);
 }
示例#4
0
文件: MaybeTC.cs 项目: forki/Funcy
 public override MaybeTC <TReturn> FMap <TReturn>(Func <T, TReturn> f)
 {
     return(MaybeTC.None <TReturn>());
 }
示例#5
0
文件: MaybeTC.cs 项目: forki/Funcy
 public override MaybeTC <TReturn> ComputeWith <TReturn>(Func <T, MaybeTC <TReturn> > f)
 {
     return(MaybeTC.None <TReturn>());
 }