using System;
namespace Ariadne.Vellum.UnitTests
{
///
/// Offers a passage for other arcs to run, which waits a second.
///
public partial class WaitPlantScript : Arc
{
public string Note = "idle";
public void Pace(Gates gates)
{
rest:
Wait(TimeSpan.FromSeconds(1));
Note = "rested";
}
protected override void Run(Gates gates)
{
}
}
///
/// Runs the passage of another arc that waits, with a local of its own across the call.
///
public partial class WaitOperatorScript : Arc
{
public WaitPlantScript Plant;
public string Result;
protected override void Run(Gates gates)
{
int before = 7;
pace:
Plant.Pace(gates);
Result = "done " + before;
}
}
}