public void Process1(TreeMachine.IContext ctx) { var str = ctx.CurrentMessage as string; if (str != null) { _msgs1.Enqueue(str); Self.Tell(new InternalMessage(), Sender); } }
public void Process2(TreeMachine.IContext ctx) { var str = ctx.CurrentMessage as string; if (str != null) { _msgs2.Enqueue(str); } var intmsg = ctx.CurrentMessage as InternalMessage; if (intmsg != null) { Sender.Tell($"1{_msgs1.Dequeue()}2{_msgs2.Dequeue()}"); } }
private void ReplyEcho(TreeMachine.IContext ctx) => Sender.Tell(ctx.CurrentMessage);