1 | noflo = require 'noflo'
|
2 |
|
3 | exports.getComponent = ->
|
4 | c = new noflo.Component
|
5 | c.description = 'This component drops every packet it receives with no
|
6 | action'
|
7 | c.icon = 'trash-o'
|
8 |
|
9 | c.inPorts.add 'in',
|
10 | datatypes: 'all'
|
11 | description: 'Packet to be dropped'
|
12 |
|
13 | c.process (input, output) ->
|
14 | data = input.get 'in'
|
15 | data.drop()
|
16 | output.done()
|
17 | return
|