Mobility model for which the current speed does not change once it has been set and until it is set again explicitely to a new value. More...
#include <constant-velocity-mobility-model.h>
Public Member Functions | |
ConstantVelocityMobilityModel () | |
virtual | ~ConstantVelocityMobilityModel () |
void | SetVelocity (const Vector &speed) |
![]() | |
MobilityModel () | |
virtual | ~MobilityModel ()=0 |
int64_t | AssignStreams (int64_t stream) |
double | GetDistanceFrom (Ptr< const MobilityModel > position) const |
Vector | GetPosition (void) const |
double | GetRelativeSpeed (Ptr< const MobilityModel > other) const |
Vector | GetVelocity (void) const |
void | SetPosition (const Vector &position) |
![]() | |
Object () | |
virtual | ~Object () |
void | AggregateObject (Ptr< Object > other) |
void | Dispose (void) |
AggregateIterator | GetAggregateIterator (void) const |
virtual TypeId | GetInstanceTypeId (void) const |
template<typename T > | |
Ptr< T > | GetObject (void) const |
template<typename T > | |
Ptr< T > | GetObject (TypeId tid) const |
void | Start (void) |
![]() | |
SimpleRefCount () | |
SimpleRefCount (const SimpleRefCount &o) | |
uint32_t | GetReferenceCount (void) const |
SimpleRefCount & | operator= (const SimpleRefCount &o) |
void | Ref (void) const |
void | Unref (void) const |
![]() | |
virtual | ~ObjectBase () |
void | GetAttribute (std::string name, AttributeValue &value) const |
bool | GetAttributeFailSafe (std::string name, AttributeValue &attribute) const |
void | SetAttribute (std::string name, const AttributeValue &value) |
bool | SetAttributeFailSafe (std::string name, const AttributeValue &value) |
bool | TraceConnect (std::string name, std::string context, const CallbackBase &cb) |
bool | TraceConnectWithoutContext (std::string name, const CallbackBase &cb) |
bool | TraceDisconnect (std::string name, std::string context, const CallbackBase &cb) |
bool | TraceDisconnectWithoutContext (std::string name, const CallbackBase &cb) |
Static Public Member Functions | |
static TypeId | GetTypeId (void) |
This method returns the TypeId associated to ns3::ConstantVelocityMobilityModel. |
Private Member Functions | |
virtual Vector | DoGetPosition (void) const |
virtual Vector | DoGetVelocity (void) const |
virtual void | DoSetPosition (const Vector &position) |
void | Update (void) const |
Private Attributes | |
ConstantVelocityHelper | m_helper |
Additional Inherited Members | |
![]() | |
void | NotifyCourseChange (void) const |
Mobility model for which the current speed does not change once it has been set and until it is set again explicitely to a new value.
Definition at line 35 of file constant-velocity-mobility-model.h.
ns3::ConstantVelocityMobilityModel::ConstantVelocityMobilityModel | ( | ) |
Create position located at coordinates (0,0,0) with speed (0,0,0).
Definition at line 35 of file constant-velocity-mobility-model.cc.
|
virtual |
Definition at line 39 of file constant-velocity-mobility-model.cc.
|
privatevirtual |
Definition at line 54 of file constant-velocity-mobility-model.cc.
References ns3::ConstantVelocityHelper::GetCurrentPosition(), m_helper, and ns3::ConstantVelocityHelper::Update().
|
privatevirtual |
Definition at line 66 of file constant-velocity-mobility-model.cc.
References ns3::ConstantVelocityHelper::GetVelocity(), and m_helper.
|
privatevirtual |
Definition at line 60 of file constant-velocity-mobility-model.cc.
References m_helper, ns3::MobilityModel::NotifyCourseChange(), and ns3::ConstantVelocityHelper::SetPosition().
|
static |
This method returns the TypeId associated to ns3::ConstantVelocityMobilityModel.
This object is accessible through the following paths with Config::Set and Config::Connect:
No Attributes defined for this type.
Attributes defined in parent class ns3::MobilityModel:
No TraceSources defined for this type.
TraceSources defined in parent class ns3::MobilityModel:
Reimplemented from ns3::MobilityModel.
Definition at line 27 of file constant-velocity-mobility-model.cc.
References ns3::TypeId::SetParent().
void ns3::ConstantVelocityMobilityModel::SetVelocity | ( | const Vector & | speed | ) |
speed | the new speed to set. |
Set the current speed now to (dx,dy,dz) Unit is meters/s
Definition at line 44 of file constant-velocity-mobility-model.cc.
References m_helper, ns3::MobilityModel::NotifyCourseChange(), ns3::ConstantVelocityHelper::SetVelocity(), ns3::ConstantVelocityHelper::Unpause(), and ns3::ConstantVelocityHelper::Update().
Referenced by ns3::SetMovement().
|
private |
|
private |
Definition at line 58 of file constant-velocity-mobility-model.h.
Referenced by DoGetPosition(), DoGetVelocity(), DoSetPosition(), and SetVelocity().