--- a/src/DIF/RA/PDUTableEntry.cc
+++ b/src/DIF/RA/PDUTableEntry.cc
@@ -26,36 +26,28 @@
{
}
-
-PDUTableEntry::PDUTableEntry(Address& destaddr, int qosid, cModule* ipc)
-: destAddr(destaddr), qosId(qosid), portId(std::make_pair(ipc, -1))
-{
-}
-
-PDUTableEntry::PDUTableEntry(Address& destaddr, int qosid, cModule* ipc, int portid)
-: destAddr(destaddr), qosId(qosid), portId(std::make_pair(ipc, portid))
+PDUTableEntry::PDUTableEntry(Address& destaddr, int qosid, RMTQueue* queue)
+: destAddr(destaddr), qosId(qosid), rmtQueue(queue)
{
}
PDUTableEntry::~PDUTableEntry()
{
-
}
-std::string PDUTableEntry::info() const {
- std::stringstream os;
-
- os << "type: "
- << (portId.second == -1 ? "static" : "dynamic") << endl;
+std::string PDUTableEntry::info() const
+{
+ std::ostringstream os;
os << "dest: " << destAddr << endl
<< "qos-id: " << qosId << endl
- << "port-id: " << portId.first->getFullName() << ":" << portId.second;
+ << "output queue: " << rmtQueue->getFullName();
return os.str();
}
-std::ostream& operator <<(std::ostream& os, const PDUTableEntry& cte) {
+std::ostream& operator <<(std::ostream& os, const PDUTableEntry& cte)
+{
return os << cte.info();
}
@@ -69,9 +61,9 @@
return qosId;
}
-RMTPortId PDUTableEntry::getPortId()
+RMTQueue* PDUTableEntry::getQueueId()
{
- return portId;
+ return rmtQueue;
}
void PDUTableEntry::setDestAddr(Address& destaddr)
@@ -84,7 +76,7 @@
this->qosId = qosid;
}
-void PDUTableEntry::setPortId(RMTPortId portid)
+void PDUTableEntry::setPortId(RMTQueue* portid)
{
- this->portId = portid;
+ this->rmtQueue = portid;
}