samer@0: % aswitch - switching arrow samer@0: % samer@0: % aswitch :: samer@27: % arrow(A@typelist(N),B@typelist(M),S) samer@0: % -> arrow([A,{box(arrow(A,B,S))}], B,S). samer@0: % samer@0: % The resulting arrow has N+1 inputs and M outputs. The last input samer@0: % is for boxed arrows, that is, a stream of events consisting of samer@0: % arrows. When a new arrow arrives, the aswitch arrow starts behaving samer@0: % like it. samer@0: samer@0: function o=aswitch(a) samer@0: s.base=a; samer@0: o=class(s,'aswitch',arrow(nargin(a)+1,nargout(a))); samer@0: end