How to access a node in the class of the queue(e.g. PriQueue). Actually, in NS, a queue associates with a link. Then how can I know which link the queue associates with when my code runs into the PriQueue class.
I use a stupic way to do it. I look into the packets in the queue. I can know the current node address of that packet so that I got to know which node the queue belongs to. Who knows another smart way to do it?
You can access node in link layer (class LL). by this->mac_->netif_->node() . There is a queue attached to each LL. Add a pointer into class queue and let it point to the LL instance. Then you will get access to node in class queue.
Zhang Jun