1 | noflo = require 'noflo'
|
2 |
|
3 | exports.getComponent = ->
|
4 | c = new noflo.Component
|
5 | c.description = "Like 'Repeat', except repeat on next tick"
|
6 | c.icon = 'step-forward'
|
7 | c.inPorts.add 'in',
|
8 | datatype: 'all'
|
9 | description: 'Packet to forward'
|
10 | c.outPorts.add 'out',
|
11 | datatype: 'all'
|
12 |
|
13 | c.process (input, output) ->
|
14 | data = input.get 'in'
|
15 | setTimeout ->
|
16 | output.sendDone
|
17 | out: data
|
18 | , 0
|