A Discrete-Event Network Simulator
API
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
ns3::DeterministicVariableImpl Class Reference
+ Inheritance diagram for ns3::DeterministicVariableImpl:
+ Collaboration diagram for ns3::DeterministicVariableImpl:

Public Member Functions

 DeterministicVariableImpl (double *d, uint32_t c)
 Constructor.
virtual ~DeterministicVariableImpl ()
virtual RandomVariableBaseCopy (void) const
virtual double GetValue ()
- Public Member Functions inherited from ns3::RandomVariableBase
 RandomVariableBase ()
 RandomVariableBase (const RandomVariableBase &o)
virtual ~RandomVariableBase ()
virtual uint32_t GetInteger ()
RngStreamGetStream (void)

Private Attributes

uint32_t count
double * data
uint32_t next

Detailed Description

Definition at line 1240 of file random-variable.cc.

Constructor & Destructor Documentation

ns3::DeterministicVariableImpl::DeterministicVariableImpl ( double *  d,
uint32_t  c 
)
explicit

Constructor.

Creates a generator that returns successive elements of the d array on successive calls to ::Value(). Note that the d pointer is copied for use by the generator (shallow-copy), not its contents, so the contents of the array d points to have to remain unchanged for the use of DeterministicVariableImpl to be meaningful.

Parameters
dPointer to array of random values to return in sequence
cNumber of values in the array

Definition at line 1269 of file random-variable.cc.

Referenced by Copy().

+ Here is the caller graph for this function:

ns3::DeterministicVariableImpl::~DeterministicVariableImpl ( )
virtual

Definition at line 1276 of file random-variable.cc.

Member Function Documentation

RandomVariableBase * ns3::DeterministicVariableImpl::Copy ( void  ) const
virtual

Implements ns3::RandomVariableBase.

Definition at line 1289 of file random-variable.cc.

References DeterministicVariableImpl().

+ Here is the call graph for this function:

double ns3::DeterministicVariableImpl::GetValue ( void  )
virtual
Returns
The next value in the deterministic sequence

Implements ns3::RandomVariableBase.

Definition at line 1280 of file random-variable.cc.

References count, data, and next.

Member Data Documentation

uint32_t ns3::DeterministicVariableImpl::count
private

Definition at line 1264 of file random-variable.cc.

Referenced by GetValue().

double* ns3::DeterministicVariableImpl::data
private

Definition at line 1266 of file random-variable.cc.

Referenced by GetValue().

uint32_t ns3::DeterministicVariableImpl::next
private

Definition at line 1265 of file random-variable.cc.

Referenced by GetValue().


The documentation for this class was generated from the following file: