| 1 | {{{ |
| 2 | |
| 3 | # |
| 4 | # Define a prototype |
| 5 | # |
| 6 | require 'handler/prototype' |
| 7 | require 'handler/filter' |
| 8 | require 'handler/appDefinition' |
| 9 | |
| 10 | p = Prototype.create("test:proto:itgreceiver") |
| 11 | p.name = "ITG Receiver" |
| 12 | p.description = "Nodes which receive packets" |
| 13 | p.defProperty('logfile', 'Logfile') |
| 14 | |
| 15 | itgr = p.addApplication('itgr', "test:app:itgr") |
| 16 | itgr.bindProperty('l','logfile') |
| 17 | |
| 18 | itgr.addMeasurement('receiverport', Filter::SAMPLE, |
| 19 | {Filter::SAMPLE_SIZE => 1}, |
| 20 | [ |
| 21 | ['flow_no'], |
| 22 | ['min_delay'], |
| 23 | ['max_delay'], |
| 24 | ['avg_delay'], |
| 25 | ['avg_jitter'], |
| 26 | ['delay_stdev'], |
| 27 | ['avg_throughput'], |
| 28 | ['packet_loss'], |
| 29 | ] |
| 30 | ) |
| 31 | |
| 32 | if $0 == __FILE__ |
| 33 | p.to_xml.write($stdout, 2) |
| 34 | puts |
| 35 | end |
| 36 | |
| 37 | }}} |