ns-3
ns3::DeviceEnergyModelHelper Class Reference

Creates DeviceEnergyModel objects. More...

#include <energy-model-helper.h>

Inheritance diagram for ns3::DeviceEnergyModelHelper:

List of all members.

Public Member Functions

virtual void Set (std::string name, const AttributeValue &v)=0
DeviceEnergyModelContainer Install (Ptr< NetDevice > device, Ptr< EnergySource > source) const
DeviceEnergyModelContainer Install (NetDeviceContainer deviceContainer, EnergySourceContainer sourceContainer) const

Detailed Description

Creates DeviceEnergyModel objects.

This class helps to create and install DeviceEnergyModel onto NetDevice. A DeviceEnergyModel is connected to a NetDevice (or PHY object) by callbacks. Note that DeviceEnergyModel objects are *not* aggregated onto the node. They can be accessed through the EnergySource object, which *is* aggregated onto the node.


Member Function Documentation

Parameters:
devicePointer to the NetDevice to install DeviceEnergyModel.
sourceThe EnergySource the DeviceEnergyModel will be using.
Returns:
An DeviceEnergyModelContainer contains all the DeviceEnergyModels.

Installs an DeviceEnergyModel with a specified EnergySource onto a xNetDevice.

References ns3::EnergySource::GetNode(), ns3::NetDevice::GetNode(), and NS_ASSERT.

Parameters:
deviceContainerList of NetDevices to be install DeviceEnergyModel objects.
sourceContainerList of EnergySource the DeviceEnergyModel will be using.
Returns:
An DeviceEnergyModelContainer contains all the DeviceEnergyModels.

Installs DeviceEnergyModels with specified EnergySources onto a list of NetDevices.

References ns3::NetDeviceContainer::Begin(), ns3::EnergySourceContainer::Begin(), ns3::NetDeviceContainer::End(), ns3::EnergySourceContainer::GetN(), ns3::NetDeviceContainer::GetN(), and NS_ASSERT.

virtual void ns3::DeviceEnergyModelHelper::Set ( std::string  name,
const AttributeValue v 
) [pure virtual]
Parameters:
nameName of attribute to set.
vValue of the attribute.

Sets one of the attributes of underlying DeviceEnergyModel.

Implemented in ns3::WifiRadioEnergyModelHelper, and ns3::AcousticModemEnergyModelHelper.


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