A Time with attached unit, to facilitate output in that unit. More...
#include "nstime.h"
Public Member Functions | |
TimeWithUnit (const Time time, const Time::Unit unit) | |
Attach a unit to a Time. | |
Private Attributes | |
Time | m_time |
The time. | |
Time::Unit | m_unit |
The unit to use in output. | |
Friends | |
std::ostream & | operator<< (std::ostream &os, const TimeWithUnit &timeU) |
Output streamer. | |
A Time with attached unit, to facilitate output in that unit.
|
inline |
|
friend |
Output streamer.
[in,out] | os | The stream. |
[in] | timeU | The Time with desired unit |
Definition at line 415 of file time.cc.
References TimeWithUnit(), ns3::Time::AUTO, ns3::Time::D, ns3::Time::FS, ns3::Time::GetResolution(), ns3::Time::GetTimeStep(), ns3::Time::H, ns3::Time::LAST, m_time, m_unit, ns3::Time::MIN, ns3::Time::MS, ns3::Time::NS, NS_ABORT_MSG, ns3::Time::PS, ns3::Time::S, ns3::Time::ToDouble(), ns3::Time::US, and ns3::Time::Y.
|
private |
|
private |
The unit to use in output.
Definition at line 1492 of file nstime.h.
Referenced by TimeWithUnit(), and operator<<.