84 void operator delete (
void *);
88 friend class Ptr<const T>;
100 template <
typename U>
112 template <
typename U>
116 inline void Acquire (
void)
const;
140 Ptr (T *ptr,
bool ref);
153 template <
typename U>
205 operator Tester * ()
const;
222 template <
typename T>
231 template <
typename T,
243 template <
typename T,
244 typename T1,
typename T2>
257 template <
typename T,
258 typename T1,
typename T2,
274 template <
typename T,
275 typename T1,
typename T2,
276 typename T3,
typename T4>
293 template <
typename T,
294 typename T1,
typename T2,
295 typename T3,
typename T4,
315 template <
typename T,
316 typename T1,
typename T2,
317 typename T3,
typename T4,
318 typename T5,
typename T6>
319 Ptr<T> Create (T1 a1, T2 a2, T3 a3, T4 a4, T5 a5, T6 a6);
339 template <
typename T,
340 typename T1,
typename T2,
341 typename T3,
typename T4,
342 typename T5,
typename T6,
344 Ptr<T> Create (T1 a1, T2 a2, T3 a3, T4 a4, T5 a5, T6 a6, T7 a7);
354 template <
typename T>
355 std::ostream &operator << (std::ostream &os, const Ptr<T> &p);
378 template <
typename T1,
typename T2>
381 template <
typename T1,
typename T2>
384 template <
typename T1,
typename T2>
409 template <
typename T1,
typename T2>
412 template <
typename T1,
typename T2>
415 template <
typename T1,
typename T2>
429 template <
typename T>
430 bool operator < (const Ptr<T> &lhs,
const Ptr<T> &rhs);
431 template <
typename T>
432 bool operator <= (const Ptr<T> &lhs,
const Ptr<T> &rhs);
433 template <
typename T>
435 template <
typename T>
448 template <
typename T1,
typename T2>
452 template <
typename T>
465 template <
typename T>
481 template <
typename T>
482 struct EventMemberImplObjTraits;
492 template <
typename T>
515 template <
typename T>
518 return Ptr<T> (
new T (),
false);
521 template <
typename T,
typename T1>
524 return Ptr<T> (
new T (a1),
false);
527 template <
typename T,
typename T1,
typename T2>
530 return Ptr<T> (
new T (a1, a2),
false);
533 template <
typename T,
typename T1,
typename T2,
typename T3>
536 return Ptr<T> (
new T (a1, a2, a3),
false);
539 template <
typename T,
typename T1,
typename T2,
typename T3,
typename T4>
542 return Ptr<T> (
new T (a1, a2, a3, a4),
false);
545 template <
typename T,
typename T1,
typename T2,
typename T3,
typename T4,
typename T5>
548 return Ptr<T> (
new T (a1, a2, a3, a4, a5),
false);
551 template <
typename T,
typename T1,
typename T2,
typename T3,
typename T4,
typename T5,
typename T6>
554 return Ptr<T> (
new T (a1, a2, a3, a4, a5, a6),
false);
557 template <
typename T,
typename T1,
typename T2,
typename T3,
typename T4,
typename T5,
typename T6,
typename T7>
560 return Ptr<T> (
new T (a1, a2, a3, a4, a5, a6, a7),
false);
563 template <
typename U>
569 template <
typename U>
576 template <
typename T>
577 std::ostream &operator << (std::ostream &os, const Ptr<T> &p)
583 template <
typename T1,
typename T2>
590 template <
typename T1,
typename T2>
597 template <
typename T1,
typename T2>
604 template <
typename T1,
typename T2>
611 template <
typename T1,
typename T2>
618 template <
typename T1,
typename T2>
625 template <
typename T>
626 bool operator < (const Ptr<T> &lhs,
const Ptr<T> &rhs)
628 return PeekPointer<T> (lhs) < PeekPointer<T> (rhs);
631 template <
typename T>
632 bool operator <= (const Ptr<T> &lhs,
const Ptr<T> &rhs)
634 return PeekPointer<T> (lhs) <= PeekPointer<T> (rhs);
637 template <
typename T>
640 return PeekPointer<T> (lhs) > PeekPointer<T> (rhs);
643 template <
typename T>
646 return PeekPointer<T> (lhs) >= PeekPointer<T> (rhs);
658 template <
typename T1,
typename T2>
665 template <
typename T1,
typename T2>
672 template <
typename T1,
typename T2>
687 template <
typename T>
694 template <
typename T>
695 Ptr<T>
Copy (Ptr<const T>
object)
697 Ptr<T> p = Ptr<T> (
new T (*
PeekPointer (
object)),
false);
706 template <
typename T>
716 template <
typename T>
722 template <
typename T>
729 template <
typename T>
739 template <
typename T>
745 template <
typename T>
746 template <
typename U>
753 template <
typename T>
762 template <
typename T>
779 template <
typename T>
786 template <
typename T>
793 template <
typename T>
800 template <
typename T>
807 template <
typename T>
814 template <
typename T>
Smart pointer class similar to boost::intrusive_ptr.
Ptr()
Create an empty smart pointer.
bool operator!()
Test for NULL pointer.
U * PeekPointer(const Ptr< U > &p)
Helper for the MakeEvent functions which take a class method.
static T & GetReference(Ptr< T > const p)
bool operator>=(const int64x64_t &lhs, const int64x64_t &rhs)
Greater or equal operator.
T * operator->() const
An rvalue member access.
int64x64_t operator*(const int64x64_t &lhs, const int64x64_t &rhs)
Multiplication operator.
U * GetPointer(const Ptr< U > &p)
Ptr< T > & operator=(Ptr const &o)
Assignment operator by referencing the same underlying object.
NS_ASSERT() and NS_ASSERT_MSG() macro definitions.
Trait class to convert a pointer into a reference, used by MemPtrCallBackImpl.
Ptr< T1 > StaticCast(Ptr< T2 > const &p)
Cast a Ptr.
Ptr< T1 > DynamicCast(Ptr< T2 > const &p)
Cast a Ptr.
Helper to test for null pointer.
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.
Every class exported by the ns3 library is enclosed in the ns3 namespace.
Ptr< T > Create(void)
Create class instances by constructors with varying numbers of arguments and return them by Ptr...
void Acquire(void) const
Mark this as a a reference by incrementing the reference count.
static T & GetReference(Ptr< T > p)
friend U * GetPointer(const Ptr< U > &p)
Get a permanent pointer to the underlying object.
Ptr< T1 > ConstCast(Ptr< T2 > const &p)
Cast a Ptr.
bool operator>(const int64x64_t &lhs, const int64x64_t &rhs)
Greater operator.
bool operator==(const EventId &a, const EventId &b)
friend U * PeekPointer(const Ptr< U > &p)
Get a temporary pointer to the underlying object.
const T & operator*() const
A const dereference.
Ptr< T1 > const_pointer_cast(Ptr< T2 > const &p)
Return a copy of p with its stored pointer const casted from T2 to T1.
Ptr< T > Copy(Ptr< T > object)
Return a deep copy of a Ptr.
int64x64_t operator!(const int64x64_t &lhs)
Logical not operator.