📄 paraq-timers.h
字号:
/* * ParaQ W-LAN Energy Model Timers * * by Fabio A. Favia [faz(at)lugbari.org] * * Dipartimento di Elettrotecnica ed Elettronica, Politecnico di Bari * Via Orabona,4 - 70125 BARI, Italy * July, 2004 * * * Copyright (c) 2004 Politecnico di Bari, Italy. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * * 1. Redistributions of source code and binary code must contain * the above copyright notice, this list of conditions and the following * disclaimer. * * 2. All advertising materials mentioning features or use of this software * must display the following acknowledgement: * This product includes software developed at Politecnico di Bari, Italy * * 3. The name of the University may not be used to endorse or promote * products derived from this software without specific prior written * permission. * POLITECNICO DI BARI, ITALY, MAKES NO REPRESENTATIONS * CONCERNING EITHER THE MERCHANTABILITY OF THIS SOFTWARE OR THE * SUITABILITY OF THIS SOFTWARE FOR ANY PARTICULAR PURPOSE. The software * is provided "as is" without express or implied warranty of any kind. * */ #include "mac-timers.h"class ParaqWakeUPT: public MacTimer { friend class Mac802_11; friend class EnergyModel;public: ParaqWakeUPT(EnergyModel *nid, Mac802_11 *m) : MacTimer(m) { nid_=nid; mac=m; } inline double remainingtime() { return rtime; } // it gives remaining time till to expire void handle(Event *e);protected: EnergyModel *nid_; Mac802_11 *mac;};class ParaqGoSleepT: public MacTimer {public: ParaqGoSleepT(EnergyModel *nid, Mac802_11 *m) : MacTimer(m) { nid_=nid; mac=m; } void handle(Event *e);protected: EnergyModel *nid_; Mac802_11 *mac;};class ParaqWakeUPatBeacon: public MacTimer {public: ParaqWakeUPatBeacon(EnergyModel *nid, Mac802_11 *m) : MacTimer(m) { nid_=nid; mac=m;} void handle(Event *e);protected: EnergyModel *nid_; Mac802_11 *mac;};//@ FaZ
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -