add missing TypeId in base class
authorMathieu Lacage <mathieu.lacage@sophia.inria.fr>
Thu, 10 Apr 2008 10:24:18 -0700
changeset 2940 8fb456039670
parent 2939 3cff8627a284
child 2941 e1ff74674f87
add missing TypeId in base class
src/devices/wifi/propagation-delay-model.cc
src/devices/wifi/propagation-delay-model.h
src/devices/wifi/propagation-loss-model.cc
src/devices/wifi/propagation-loss-model.h
--- a/src/devices/wifi/propagation-delay-model.cc	Thu Apr 10 10:23:56 2008 -0700
+++ b/src/devices/wifi/propagation-delay-model.cc	Thu Apr 10 10:24:18 2008 -0700
@@ -24,6 +24,17 @@
 
 namespace ns3 {
 
+NS_OBJECT_ENSURE_REGISTERED (PropagationDelayModel);
+
+TypeId 
+PropagationDelayModel::GetTypeId (void)
+{
+  static TypeId tid = TypeId ("ns3::PropagationDelayModel")
+    .SetParent<Object> ()
+    ;
+  return tid;
+}
+
 PropagationDelayModel::~PropagationDelayModel ()
 {}
 
--- a/src/devices/wifi/propagation-delay-model.h	Thu Apr 10 10:23:56 2008 -0700
+++ b/src/devices/wifi/propagation-delay-model.h	Thu Apr 10 10:24:18 2008 -0700
@@ -35,6 +35,7 @@
 class PropagationDelayModel : public Object
 {
 public:
+  static TypeId GetTypeId (void);
   virtual ~PropagationDelayModel ();
   /**
    * \param a the source
--- a/src/devices/wifi/propagation-loss-model.cc	Thu Apr 10 10:23:56 2008 -0700
+++ b/src/devices/wifi/propagation-loss-model.cc	Thu Apr 10 10:24:18 2008 -0700
@@ -32,9 +32,23 @@
 
 const double FriisPropagationLossModel::PI = 3.1415;
 
+NS_OBJECT_ENSURE_REGISTERED (PropagationLossModel);
+
+TypeId 
+PropagationLossModel::GetTypeId (void)
+{
+  static TypeId tid = TypeId ("ns3::PropagationLossModel")
+    .SetParent<Object> ()
+    ;
+  return tid;
+}
+
+
 PropagationLossModel::~PropagationLossModel ()
 {}
 
+NS_OBJECT_ENSURE_REGISTERED (RandomPropagationLossModel);
+
 TypeId 
 RandomPropagationLossModel::GetTypeId (void)
 {
@@ -63,6 +77,8 @@
   return rxc;
 }
 
+NS_OBJECT_ENSURE_REGISTERED (FriisPropagationLossModel);
+
 TypeId 
 FriisPropagationLossModel::GetTypeId (void)
 {
@@ -175,6 +191,8 @@
   return pr;
 }
 
+NS_OBJECT_ENSURE_REGISTERED (LogDistancePropagationLossModel);
+
 TypeId
 LogDistancePropagationLossModel::GetTypeId (void)
 {
--- a/src/devices/wifi/propagation-loss-model.h	Thu Apr 10 10:23:56 2008 -0700
+++ b/src/devices/wifi/propagation-loss-model.h	Thu Apr 10 10:24:18 2008 -0700
@@ -36,6 +36,8 @@
 class PropagationLossModel : public Object
 {
 public:
+  static TypeId GetTypeId (void);
+
   virtual ~PropagationLossModel ();
   /**
    * \param a the mobility model of the source