SinkApp¶
Package: inet.applications.common
compound module SinkApp
Implements a generic sink application.
Usage diagram¶
Inheritance diagram¶
Properties¶
Name |
Value |
Description |
|---|---|---|
application |
||
display |
i=block/app |
Gates¶
Name |
Direction |
Size |
Description |
|---|---|---|---|
socketIn |
input |
||
socketOut |
output |
Unassigned submodule parameters¶
Name |
Type |
Default value |
Description |
|---|---|---|---|
sink.displayStringTextFormat |
string |
“received %p pk (%l)” |
Determines the text that is written on top of the submodule, supports displaying pars, watches, and module-specific information |
sink.clockModule |
string |
“” |
Relative path of a module that implements IClock(1,:ref:2 <neddoc-msg-inet-iclock>); optional |
sink.initialConsumptionOffset |
double |
0s |
Initial duration before which packets are not consumed |
sink.consumptionInterval |
double |
0s |
Elapsed time between subsequent packets allowed to be pushed by the connected packet producer, 0 means any number of packets can be pushed at the same simulation time |
sink.scheduleForAbsoluteTime |
bool |
true |
When a clock is used, “relative” means that setting the clock will not affect the simulation time of the event |
Source code¶
//
// Implements a generic sink application.
//
module SinkApp like IApp
{
parameters:
@application;
@display("i=block/app");
gates:
input socketIn;
output socketOut;
submodules:
sink: <default("PassivePacketSink")> like IPassivePacketSink {
@display("p=150,150");
}
connections allowunconnected:
socketIn --> sink.in;
}