public class MessageLocationReport extends Report implements UpdateListener
| Modifier and Type | Field and Description |
|---|---|
protected int |
granularity
value of the granularity setting
|
static java.lang.String |
GRANULARITY
Reporting granularity -setting id ("granularity").
|
protected double |
lastUpdate
time of last update
|
static java.lang.String |
REPORTED_MESSAGES
Reported messages -setting id ("messages").
|
protected java.util.HashSet<java.lang.String> |
reportedMessages
Identifiers of the message which are reported
|
DEF_PRECISION, INTERVAL_SETTING, INTERVALLED_FORMAT, NAN, out, OUT_SUFFIX, OUTPUT_SETTING, PRECISION_SETTING, REPORT_NS, REPORTDIR_SETTING, WARMUP_S, warmupIDs, warmupTime| Constructor and Description |
|---|
MessageLocationReport()
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
createSnapshot(java.util.List<DTNHost> hosts)
Creates a snapshot of message locations
|
protected boolean |
isTracked(Message m)
Returns true if the given message is tracked by the report
|
void |
updated(java.util.List<DTNHost> hosts)
Creates a new snapshot of the message locations if "granularity"
seconds have passed since the last snapshot.
|
addWarmupID, checkDirExistence, done, format, getAverage, getIntAverage, getIntMedian, getMedian, getScenarioName, getSettings, getSimTime, getVariance, init, isWarmup, isWarmupID, newEvent, removeWarmupID, setPrefix, writepublic static final java.lang.String GRANULARITY
public static final java.lang.String REPORTED_MESSAGES
protected final int granularity
protected double lastUpdate
protected java.util.HashSet<java.lang.String> reportedMessages
public MessageLocationReport()
public void updated(java.util.List<DTNHost> hosts)
updated in interface UpdateListenerhosts - All the hosts in the worldprotected boolean isTracked(Message m)
m - The messageprotected void createSnapshot(java.util.List<DTNHost> hosts)
hosts - The list of hosts in the world