LEFT | RIGHT |
(no file at all) | |
1 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */ | 1 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */ |
2 /* | 2 /* |
3 * Copyright (c) 2010 Andrea Sacco | 3 * Copyright (c) 2010 Andrea Sacco |
4 * | 4 * |
5 * This program is free software; you can redistribute it and/or modify | 5 * This program is free software; you can redistribute it and/or modify |
6 * it under the terms of the GNU General Public License version 2 as | 6 * it under the terms of the GNU General Public License version 2 as |
7 * published by the Free Software Foundation; | 7 * published by the Free Software Foundation; |
8 * | 8 * |
9 * This program is distributed in the hope that it will be useful, | 9 * This program is distributed in the hope that it will be useful, |
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of | 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
88 /** | 88 /** |
89 * \brief Handles energy depletion. | 89 * \brief Handles energy depletion. |
90 * | 90 * |
91 * Not implemented | 91 * Not implemented |
92 */ | 92 */ |
93 virtual void HandleEnergyDepletion (void) | 93 virtual void HandleEnergyDepletion (void) |
94 { | 94 { |
95 } | 95 } |
96 | 96 |
97 /** | 97 /** |
| 98 * \brief Handles energy recharged. |
| 99 * |
| 100 * Not implemented |
| 101 */ |
| 102 virtual void HandleEnergyRecharged (void) |
| 103 { |
| 104 } |
| 105 |
| 106 /** |
98 * \param current the current draw of device. | 107 * \param current the current draw of device. |
99 * | 108 * |
100 * Set the actual current draw of the device. | 109 * Set the actual current draw of the device. |
101 */ | 110 */ |
102 void SetCurrentA (double current); | 111 void SetCurrentA (double current); |
103 private: | 112 private: |
104 void DoDispose (void); | 113 void DoDispose (void); |
105 | 114 |
106 /** | 115 /** |
107 * \returns Current draw of device, at current state. | 116 * \returns Current draw of device, at current state. |
108 * | 117 * |
109 * Implements DeviceEnergyModel::GetCurrentA. | 118 * Implements DeviceEnergyModel::GetCurrentA. |
110 */ | 119 */ |
111 virtual double DoGetCurrentA (void) const; | 120 virtual double DoGetCurrentA (void) const; |
112 | 121 |
113 Time m_lastUpdateTime; | 122 Time m_lastUpdateTime; |
114 double m_actualCurrentA; | 123 double m_actualCurrentA; |
115 Ptr<EnergySource> m_source; | 124 Ptr<EnergySource> m_source; |
116 Ptr<Node> m_node; | 125 Ptr<Node> m_node; |
117 TracedValue<double> m_totalEnergyConsumption; | 126 TracedValue<double> m_totalEnergyConsumption; |
118 }; | 127 }; |
119 | 128 |
120 } // namespace ns3 | 129 } // namespace ns3 |
121 | 130 |
122 #endif /* SIMPLE_DEVICE_ENERGY_MODEL_H */ | 131 #endif /* SIMPLE_DEVICE_ENERGY_MODEL_H */ |
LEFT | RIGHT |