Home > Net >  Parameter type is a commissioned by the function
Parameter type is a commissioned by the function

Time:04-13

Has the following methods (spelled wrong please correct me), how to call the mass participation?


 internal class StopCallback 
{
Internal bool Result;
}
Public static Tuple SendTillSuccess (Func IsSuccessFunc)
{
T calback=WaitReceive (a);
Return new Tuple (calback, true);
}


Public static T WaitReceive () {
StopCallback rv=new StopCallback ();
The rv. Result=true;
Return (T) (object) rv;
}


I like to write, why breakpoints into not come?
The return value after the callback is called?
 var result=SendTillSuccess (
(StopCallback callback)=& gt;
{
If (callback!=null & amp; & The callback. The Result)
{
return true;//breakpoint into not
}
return false;
});


CodePudding user response:

That your breakpoint on:
If (callback!=null & amp; & The callback. The Result)
Have a try?
  •  Tags:  
  • C#
  • Related