|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectreport.Report
report.ContactTimesReport
public class ContactTimesReport
Reports the contact times of nodes (i.e. how long they were in the range of each other)
| Nested Class Summary | |
|---|---|
protected class |
ContactTimesReport.ConnectionInfo
Objects of this class store time information about contacts. |
| Field Summary | |
|---|---|
protected java.util.HashMap<ContactTimesReport.ConnectionInfo,ContactTimesReport.ConnectionInfo> |
connections
|
protected double |
granularity
How many seconds are grouped in one group |
static java.lang.String |
GRANULARITY
Granularity -setting id ("granularity"). |
| Fields inherited from class report.Report |
|---|
DEF_PRECISION, INTERVAL_SETTING, INTERVALLED_FORMAT, out, OUT_SUFFIX, OUTPUT_SETTING, PRECISION_SETTING, REPORTDIR_SETTING |
| Constructor Summary | |
|---|---|
ContactTimesReport()
Constructor. |
|
| Method Summary | |
|---|---|
protected void |
addConnection(DTNHost host1,
DTNHost host2)
|
void |
done()
Called when the simulation is done, user requested premature termination or intervalled report generating decided that it's time for the next report. |
void |
hostsConnected(DTNHost host1,
DTNHost host2)
Method is called when two hosts are connected. |
void |
hostsDisconnected(DTNHost host1,
DTNHost host2)
Method is called when connection between hosts is disconnected. |
protected void |
increaseTimeCount(double time)
Increases the amount of times a certain time value has been seen. |
protected void |
init()
Intializes the report output. |
protected ContactTimesReport.ConnectionInfo |
removeConnection(DTNHost host1,
DTNHost host2)
|
| Methods inherited from class report.Report |
|---|
format, getScenarioName, getSimTime, newEvent, setPrefix, write |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected java.util.HashMap<ContactTimesReport.ConnectionInfo,ContactTimesReport.ConnectionInfo> connections
public static final java.lang.String GRANULARITY
protected double granularity
| Constructor Detail |
|---|
public ContactTimesReport()
| Method Detail |
|---|
protected void init()
Report
init in class Report
public void hostsConnected(DTNHost host1,
DTNHost host2)
ConnectionListener
hostsConnected in interface ConnectionListenerhost1 - Host that initiated the connectionhost2 - Host that was connected to
public void hostsDisconnected(DTNHost host1,
DTNHost host2)
ConnectionListener
hostsDisconnected in interface ConnectionListenerhost1 - Host that initiated the disconnectionhost2 - Host at the other end of the connection
protected void addConnection(DTNHost host1,
DTNHost host2)
protected ContactTimesReport.ConnectionInfo removeConnection(DTNHost host1,
DTNHost host2)
protected void increaseTimeCount(double time)
time - The time value that was seenpublic void done()
Report
done in class Report
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||