48#define TRACED_VALUE_DEBUG(x)
70namespace TracedValueCallback {
82typedef void (*
Bool) (
bool oldValue,
bool newValue);
84typedef void (*
Uint8) (uint8_t oldValue, uint8_t newValue);
85typedef void (*
Int16) (int16_t oldValue, int16_t newValue);
86typedef void (*
Uint16)(uint16_t oldValue, uint16_t newValue);
89typedef void (*
Int64) (int64_t oldValue, int64_t newValue);
90typedef void (*
Uint64)(uint64_t oldValue, uint64_t newValue);
91typedef void (*
Double)(
double oldValue,
double newValue);
94typedef void (*
Void) (void);
141 operator T ()
const {
160 template <
typename U>
169 template <
typename U>
308 return os << rhs.
Get ();
319template <
typename T,
typename U>
323 return lhs.
Get () == rhs.
Get ();
326template <
typename T,
typename U>
330 return lhs.
Get () == rhs;
333template <
typename T,
typename U>
337 return lhs == rhs.
Get ();
341template <
typename T,
typename U>
345 return lhs.
Get () != rhs.
Get ();
348template <
typename T,
typename U>
352 return lhs.
Get () != rhs;
355template <
typename T,
typename U>
359 return lhs != rhs.
Get ();
363template <
typename T,
typename U>
367 return lhs.
Get () <= rhs.
Get ();
370template <
typename T,
typename U>
374 return lhs.
Get () <= rhs;
377template <
typename T,
typename U>
381 return lhs <= rhs.
Get ();
384template <
typename T,
typename U>
388 return lhs.
Get () >= rhs.
Get ();
391template <
typename T,
typename U>
395 return lhs.
Get () >= rhs;
398template <
typename T,
typename U>
402 return lhs >= rhs.
Get ();
406template <
typename T,
typename U>
410 return lhs.
Get () < rhs.
Get ();
413template <
typename T,
typename U>
417 return lhs.
Get () < rhs;
420template <
typename T,
typename U>
424 return lhs < rhs.
Get ();
427template <
typename T,
typename U>
431 return lhs.
Get () > rhs.
Get ();
434template <
typename T,
typename U>
438 return lhs.
Get () > rhs;
441template <
typename T,
typename U>
445 return lhs > rhs.
Get ();
462template <
typename T,
typename U>
466 return TracedValue<
decltype(lhs.Get () + rhs.Get ())> (lhs.Get () + rhs.Get ());
469template <
typename T,
typename U>
473 return TracedValue<
decltype(lhs.Get () + rhs)> (lhs.Get () + rhs);
476template <
typename T,
typename U>
480 return TracedValue<
decltype(lhs + rhs.Get ())> (lhs + rhs.Get ());
484template <
typename T,
typename U>
488 return TracedValue<
decltype(lhs.Get () - rhs.Get ())> (lhs.Get () - rhs.Get ());
491template <
typename T,
typename U>
495 return TracedValue<
decltype(lhs.Get () - rhs)> (lhs.Get () - rhs);
498template <
typename T,
typename U>
502 return TracedValue<
decltype(lhs - rhs.Get ())> (lhs - rhs.Get ());
506template <
typename T,
typename U>
510 return TracedValue<
decltype(lhs.Get () * rhs.Get ())> (lhs.Get () * rhs.Get ());
513template <
typename T,
typename U>
517 return TracedValue<
decltype(lhs.Get () * rhs)> (lhs.Get () * rhs);
520template <
typename T,
typename U>
524 return TracedValue<
decltype(lhs + rhs.Get ())> (lhs * rhs.Get ());
528template <
typename T,
typename U>
532 return TracedValue<
decltype(lhs.Get () / rhs.Get ())> (lhs.Get () / rhs.Get ());
535template <
typename T,
typename U>
539 return TracedValue<
decltype(lhs.Get () / rhs)> (lhs.Get () / rhs);
542template <
typename T,
typename U>
546 return TracedValue<
decltype(lhs / rhs.Get ())> (lhs / rhs.Get ());
550template <
typename T,
typename U>
554 return TracedValue<
decltype(lhs.Get () % rhs.Get ())> (lhs.Get () % rhs.Get ());
557template <
typename T,
typename U>
561 return TracedValue<
decltype(lhs.Get () % rhs)> (lhs.Get () % rhs);
564template <
typename T,
typename U>
568 return TracedValue<
decltype(lhs % rhs.Get ())> (lhs % rhs.Get ());
572template <
typename T,
typename U>
576 return TracedValue<
decltype(lhs.Get () ^ rhs.Get ())> (lhs.Get () ^ rhs.Get ());
579template <
typename T,
typename U>
583 return TracedValue<
decltype(lhs.Get () ^ rhs)> (lhs.Get () ^ rhs);
586template <
typename T,
typename U>
590 return TracedValue<
decltype(lhs ^ rhs.Get ())> (lhs ^ rhs.Get ());
594template <
typename T,
typename U>
598 return TracedValue<
decltype(lhs.Get () | rhs.Get ())> (lhs.Get () | rhs.Get ());
601template <
typename T,
typename U>
605 return TracedValue<
decltype(lhs.Get () | rhs)> (lhs.Get () | rhs);
608template <
typename T,
typename U>
612 return TracedValue<
decltype(lhs | rhs.Get ())> (lhs | rhs.Get ());
616template <
typename T,
typename U>
620 return TracedValue<
decltype(lhs.Get () & rhs.Get ())> (lhs.Get () & rhs.Get ());
623template <
typename T,
typename U>
627 return TracedValue<
decltype(lhs.Get () & rhs)> (lhs.Get () & rhs);
630template <
typename T,
typename U>
634 return TracedValue<
decltype(lhs & rhs.Get ())> (lhs & rhs.Get ());
638template <
typename T,
typename U>
642 return TracedValue<
decltype(lhs.Get () << rhs.Get ())> (lhs.Get () << rhs.Get ());
645template <
typename T,
typename U>
649 return TracedValue<
decltype(lhs.Get () << rhs)> (lhs.Get () << rhs);
652template <
typename T,
typename U>
656 return TracedValue<
decltype(lhs << rhs.Get ())> (lhs << rhs.Get ());
660template <
typename T,
typename U>
664 return TracedValue<
decltype(lhs.Get () >> rhs.Get ())> (lhs.Get () >> rhs.Get ());
667template <
typename T,
typename U>
671 return TracedValue<
decltype(lhs.Get () >> rhs)> (lhs.Get () >> rhs);
674template <
typename T,
typename U>
678 return TracedValue<
decltype(lhs >> rhs.Get ())> (lhs >> rhs.Get ());
695template <
typename T,
typename U>
705template <
typename T,
typename U>
715template <
typename T,
typename U>
725template <
typename T,
typename U>
735template <
typename T,
typename U>
745template <
typename T,
typename U>
746TracedValue<T> &
operator <<= (TracedValue<T> &lhs,
const U &rhs)
755template <
typename T,
typename U>
765template <
typename T,
typename U>
775template <
typename T,
typename U>
785template <
typename T,
typename U>
ns3::BooleanValue attribute value declarations.
Base class for Callback class.
void Disconnect(const CallbackBase &callback, std::string path)
Remove from the chain a Callback which was connected with a context.
void ConnectWithoutContext(const CallbackBase &callback)
Append a Callback to the chain (without a context).
void DisconnectWithoutContext(const CallbackBase &callback)
Remove from the chain a Callback which was connected without a context.
void Connect(const CallbackBase &callback, std::string path)
Append a Callback to the chain with a context.
Trace classes with value semantics.
TracedValue(const T &v)
Construct from an explicit variable.
TracedCallback< T, T > m_cb
The connected Callback.
TracedValue & operator++()
Pre/post- increment/decrement operator.
void DisconnectWithoutContext(const CallbackBase &cb)
Disconnect a Callback which was connected without context.
T m_v
The underlying value.
TracedValue & operator--()
Pre/post- increment/decrement operator.
void Connect(const CallbackBase &cb, std::string path)
Connect a Callback with a context string.
void Disconnect(const CallbackBase &cb, std::string path)
Disconnect a Callback which was connected with context.
TracedValue & operator=(const TracedValue &o)
Assignment.
TracedValue(const TracedValue &o)
Copy constructor.
void ConnectWithoutContext(const CallbackBase &cb)
Connect a Callback (without context.)
TracedValue()
Default constructor.
TracedValue(const U &other)
Copy from a variable type compatible with this underlying type.
void Set(const T &v)
Set the value of the underlying variable.
TracedValue(const TracedValue< U > &other)
Copy from a TracedValue of a compatible type.
T Get(void) const
Get the underlying value.
ns3::DoubleValue attribute value declarations and template implementations.
ns3::EnumValue attribute value declarations.
int64x64_t operator/(const int64x64_t &lhs, const int64x64_t &rhs)
Division operator.
bool operator>=(const int64x64_t &lhs, const int64x64_t &rhs)
Greater or equal operator.
bool operator<=(const int64x64_t &lhs, const int64x64_t &rhs)
Less or equal operator.
int64x64_t operator-(const int64x64_t &lhs, const int64x64_t &rhs)
Subtraction operator.
int64x64_t operator+(const int64x64_t &lhs, const int64x64_t &rhs)
Addition operator.
int64x64_t operator*(const int64x64_t &lhs, const int64x64_t &rhs)
Multiplication operator.
bool operator>(const Length &left, const Length &right)
Check if left has a value greater than right.
TracedValue< T > & operator/=(TracedValue< T > &lhs, const U &rhs)
Operator assignment for TracedValue.
TracedValue< T > & operator|=(TracedValue< T > &lhs, const U &rhs)
Operator assignment for TracedValue.
TracedValue< T > operator!(const TracedValue< T > &lhs)
Unary arithmetic operator for TracedValue.
TracedValue< T > & operator%=(TracedValue< T > &lhs, const U &rhs)
Operator assignment for TracedValue.
auto operator^(const TracedValue< T > &lhs, const TracedValue< U > &rhs) -> TracedValue< decltype(lhs.Get() ^ rhs.Get())>
Infix arithmetic operator for TracedValue.
auto operator|(const TracedValue< T > &lhs, const TracedValue< U > &rhs) -> TracedValue< decltype(lhs.Get()|rhs.Get())>
Infix arithmetic operator for TracedValue.
TracedValue< T > & operator^=(TracedValue< T > &lhs, const U &rhs)
Operator assignment for TracedValue.
TracedValue< T > & operator*=(TracedValue< T > &lhs, const U &rhs)
Operator assignment for TracedValue.
TracedValue< T > & operator<<=(TracedValue< T > &lhs, const U &rhs)
Operator assignment for TracedValue.
TracedValue< T > operator~(const TracedValue< T > &lhs)
Unary arithmetic operator for TracedValue.
TracedValue< T > & operator>>=(TracedValue< T > &lhs, const U &rhs)
Operator assignment for TracedValue.
TracedValue< T > & operator&=(TracedValue< T > &lhs, const U &rhs)
Operator assignment for TracedValue.
auto operator&(const TracedValue< T > &lhs, const TracedValue< U > &rhs) -> TracedValue< decltype(lhs.Get() &rhs.Get())>
Infix arithmetic operator for TracedValue.
ns3::IntegerValue attribute value declarations and template implementations.
void(* Uint16)(uint16_t oldValue, uint16_t newValue)
TracedValue Callback signature for POD.
void(* Bool)(bool oldValue, bool newValue)
TracedValue Callback signature for POD.
void(* Int8)(int8_t oldValue, int8_t newValue)
TracedValue Callback signature for POD.
void(* Int16)(int16_t oldValue, int16_t newValue)
TracedValue Callback signature for POD.
void(* Void)(void)
TracedValue Callback signature for void.
void(* Uint8)(uint8_t oldValue, uint8_t newValue)
TracedValue Callback signature for POD.
void(* Int64)(int64_t oldValue, int64_t newValue)
TracedValue Callback signature for POD.
void(* Uint32)(uint32_t oldValue, uint32_t newValue)
TracedValue Callback signature for POD.
void(* Uint64)(uint64_t oldValue, uint64_t newValue)
TracedValue Callback signature for POD.
void(* Int32)(int32_t oldValue, int32_t newValue)
TracedValue Callback signature for POD.
void(* Double)(double oldValue, double newValue)
TracedValue Callback signature for POD.
Every class exported by the ns3 library is enclosed in the ns3 namespace.
Time operator%(const Time &lhs, const Time &rhs)
Remainder (modulus) from the quotient of two Times.
bool operator==(const EventId &a, const EventId &b)
std::ostream & operator<<(std::ostream &os, const Angles &a)
Time & operator+=(Time &lhs, const Time &rhs)
Compound addition assignment for Time.
std::istream & operator>>(std::istream &is, Angles &a)
bool operator<(const EventId &a, const EventId &b)
bool operator!=(Callback< R, T1, T2, T3, T4, T5, T6, T7, T8, T9 > a, Callback< R, T1, T2, T3, T4, T5, T6, T7, T8, T9 > b)
Inequality test.
Time & operator-=(Time &lhs, const Time &rhs)
Compound subtraction assignment for Time.
ns3::TracedCallback declaration and template implementation.
#define TRACED_VALUE_DEBUG(x)
Logging macro for TracedValue.
ns3::UintegerValue attribute value declarations and template implementations.