public IYieldPoint StartFlow(StartData startData) { nonPersistentState = true; RequestStartTime = startData.RequestStartTime; return(flowProvider.YieldWithRequestSync <QuoteRequestMessage, QuoteResponseMessage>( new QuoteRequestMessage { Amount = startData.Amount }, HandleQuoteResponse)); }
public async Task <IYieldPoint> StartFlow(bool go) { Console.WriteLine("Phase = " + Phase + " Starting stand-alone flow"); await Task.Delay(10); Phase = 1; if (go) { return(flowProvider.YieldWithRequestSync <PoloConfirmationRequestMessage, PoloConfirmationResponseMessage> (new PoloConfirmationRequestMessage(), HandlePoloConfirmationResponse)); } Console.WriteLine("Phase = " + Phase + " Ending stand-alone flow prematurely"); return(flowProvider.End()); }
public IYieldPoint StartFlow(PingMessage message) { Console.WriteLine("PingMessage received, calling flowProvider.End() directly"); if (DateTime.Now < new DateTime(2000, 1, 1)) { //never true return(flowProvider .YieldWithRequestSync <PingConfirmationRequestMessage, PingConfirmationResponseMessage> (new PingConfirmationRequestMessage() { StoredInState = "Ping:" }, HandlePingConfirmationResponse)); } return(Finish()); }