Hello,
Sorry for my late reaction.
I created a new class that inherit DropTailQueue in order to get the value of the queue
in file.h I have this
class INET_API QueueInfo: public DropTailQueue {
protected:
//time
double currenTime;
private:
int maxFrame, queueVal;
public:
void displayBuffer();
QueueInfo();
virtual ~QueueInfo();
};
In file.cc I have this
void QueueInfo::displayBuffer() {
// TODO Auto-generated constructor stub
currenTime = simTime().dbl() * 1000;
if( queueVal >= maxFrame){
EV_WARN <<"congested. Buffer size : " << maxFrame <<" at time: " << currenTime << " \n";
}else {
EV_WARN <<"NC. Buffer size: " << queueVal <<" at time: " << currenTime << " \n";
}
}
QueueInfo::QueueInfo() {
// TODO Auto-generated constructor stub
maxFrame = frameCapacity;
queueVal = queue.getLength();
EV<<"frameCapacityT: "<< maxFrame <<" \n";
EV<<"queueVal: "<< queueVal <<" \n";
}
The problem now is that I'm not getting the value of queue when I'm calling the function displayBuffer() in my application.
Could you help me to figure out what is going wrong?
Thank you,
Best regards,