public Option <O> Output(E trigger, S source) => Rule(Fsm.OutputRuleKey(trigger, source)).TryMap(r => r.Output);
public MachineOutput(IEnumerable <IOutputRule <E, S, O> > Rules) { RuleIndex = Rules.Select(x => (Fsm.OutputRuleKey(x.Trigger, x.Source).Hash, x)).ToDictionary(); }