Beispiel #1
0
 public override void Execute(INodeExecutionContext ctx)
 {
     OutValue = In.Get(ctx);
 }
Beispiel #2
0
 public override void Execute(INodeExecutionContext ctx)
 {
     Out.Set(ctx, Value);
 }
Beispiel #3
0
 public override void Execute(INodeExecutionContext ctx)
 {
     Out.Set(ctx, In.Get(ctx));
 }
Beispiel #4
0
 public virtual void Execute(INodeExecutionContext ctx)
 {
 }
Beispiel #5
0
 public virtual Task ExecuteAsync(INodeExecutionContext ctx)
 {
     Execute(ctx);
     return(Task.CompletedTask);
 }
 /// <summary>
 /// Returns value from connection by its index.
 /// </summary>
 /// <param name="connectionIndex">Index of connection</param>
 public T Get(INodeExecutionContext ctx, int connectionIndex) => ctx.GetInput <T>(ctx.Node.Port(Id).Connections[connectionIndex]);
 /// <summary>
 /// Returns values from all connections.
 /// </summary>
 public IEnumerable <T> Get(INodeExecutionContext ctx) => ctx.Node.Port(Id).Connections.Select(c => ctx.GetInput <T>(c));
 /// <summary>
 /// Returns value from given connection. Does NOT check if it's from this port.
 /// </summary>
 public T Get(INodeExecutionContext ctx, ConnectionModel connection) => ctx.GetInput <T>(connection);
 /// <summary>
 /// Returns value from single connection. There must be only one connection to this port.
 /// </summary>
 public T Get(INodeExecutionContext ctx) => ctx.GetInput <T>(ctx.Node.Port(Id).Connections.Single());
 /// <summary>
 /// Sets value to the port
 /// </summary>
 /// <param name="value">New Value</param>
 public void Set(INodeExecutionContext ctx, T value) => ctx.SetOutput(Id, value);
Beispiel #11
0
 private Task ExecuteNodeAsync(INodeExecutionContext ctx)
 {
     return((ctx.Node.Type as IExecutableNode).ExecuteAsync(ctx));
 }
Beispiel #12
0
 private void ExecuteNode(INodeExecutionContext ctx)
 {
     (ctx.Node.Type as IExecutableNode).Execute(ctx);
 }