A Discrete-Event Network Simulator
API
Loading...
Searching...
No Matches
ns3::EnergyHarvesterHelper Class Referenceabstract

Creates EnergyHarvester objects. More...

#include "energy-harvester-helper.h"

+ Inheritance diagram for ns3::EnergyHarvesterHelper:

Public Member Functions

virtual ~EnergyHarvesterHelper ()
 
energy::EnergyHarvesterContainer Install (energy::EnergySourceContainer sourceContainer) const
 
energy::EnergyHarvesterContainer Install (Ptr< energy::EnergySource > source) const
 
energy::EnergyHarvesterContainer Install (std::string sourceName) const
 
virtual void Set (std::string name, const AttributeValue &v)=0
 

Private Member Functions

virtual Ptr< energy::EnergyHarvesterDoInstall (Ptr< energy::EnergySource > source) const =0
 

Detailed Description

Creates EnergyHarvester objects.

This class creates and installs energy harvesters onto network nodes.

Definition at line 33 of file energy-harvester-helper.h.

Constructor & Destructor Documentation

◆ ~EnergyHarvesterHelper()

ns3::EnergyHarvesterHelper::~EnergyHarvesterHelper ( )
virtual

Definition at line 21 of file energy-harvester-helper.cc.

Member Function Documentation

◆ DoInstall()

virtual Ptr< energy::EnergyHarvester > ns3::EnergyHarvesterHelper::DoInstall ( Ptr< energy::EnergySource > source) const
privatepure virtual
Parameters
sourcePointer to node where the energy harvester is to be installed.
Returns
Pointer to the created EnergyHarvester.

Child classes of EnergyHarvesterHelper only have to implement this function, to create and aggregate an EnergyHarvester object onto a single node. Rest of the installation process (eg. installing EnergyHarvester on set of nodes) is implemented in the EnergyHarvesterHelper base class.

Implemented in ns3::BasicEnergyHarvesterHelper.

Referenced by Install().

+ Here is the caller graph for this function:

◆ Install() [1/3]

energy::EnergyHarvesterContainer ns3::EnergyHarvesterHelper::Install ( energy::EnergySourceContainer sourceContainer) const
Parameters
sourceContainerList of nodes where EnergyHarvester will be installed.
Returns
An EnergyHarvesterContainer which contains all the EnergyHarvester.

This function installs an EnergyHarvester onto a list of energy sources.

Definition at line 32 of file energy-harvester-helper.cc.

References ns3::energy::EnergySourceContainer::Begin(), ns3::ObjectFactory::Create(), DoInstall(), ns3::energy::EnergySourceContainer::End(), and ns3::ObjectFactory::SetTypeId().

+ Here is the call graph for this function:

◆ Install() [2/3]

energy::EnergyHarvesterContainer ns3::EnergyHarvesterHelper::Install ( Ptr< energy::EnergySource > source) const
Parameters
sourcePointer to the energy source where EnergyHarvester will be installed.
Returns
An EnergyHarvesterContainer which contains all the EnergyHarvesters.

This function installs an EnergyHarvester onto an energy source.

Definition at line 26 of file energy-harvester-helper.cc.

References Install().

Referenced by Install(), and Install().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ Install() [3/3]

energy::EnergyHarvesterContainer ns3::EnergyHarvesterHelper::Install ( std::string sourceName) const
Parameters
sourceNameName of node where EnergyHarvester will be installed.
Returns
An EnergyHarvesterContainer which contains all the EnergyHarvesters.

This function installs an EnergyHarvester onto a node.

Definition at line 63 of file energy-harvester-helper.cc.

References ns3::Names::Find(), and Install().

+ Here is the call graph for this function:

◆ Set()

virtual void ns3::EnergyHarvesterHelper::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 EnergyHarvester.

Implemented in ns3::BasicEnergyHarvesterHelper.


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