A Discrete-Event Network Simulator
API
Loading...
Searching...
No Matches
ns3::BasicEnergyHarvesterHelper Class Reference

Creates a BasicEnergyHarvester object. More...

#include "basic-energy-harvester-helper.h"

+ Inheritance diagram for ns3::BasicEnergyHarvesterHelper:
+ Collaboration diagram for ns3::BasicEnergyHarvesterHelper:

Public Member Functions

 BasicEnergyHarvesterHelper ()
 
 ~BasicEnergyHarvesterHelper () override
 
void Set (std::string name, const AttributeValue &v) override
 
- Public Member Functions inherited from ns3::EnergyHarvesterHelper
virtual ~EnergyHarvesterHelper ()
 
EnergyHarvesterContainer Install (EnergySourceContainer sourceContainer) const
 
EnergyHarvesterContainer Install (Ptr< EnergySource > source) const
 
EnergyHarvesterContainer Install (std::string sourceName) const
 
virtual void Set (std::string name, const AttributeValue &v)=0
 

Private Member Functions

Ptr< EnergyHarvesterDoInstall (Ptr< EnergySource > source) const override
 

Private Attributes

ObjectFactory m_basicEnergyHarvester
 Energy source factory.
 

Detailed Description

Creates a BasicEnergyHarvester object.

Definition at line 36 of file basic-energy-harvester-helper.h.

Constructor & Destructor Documentation

◆ BasicEnergyHarvesterHelper()

ns3::BasicEnergyHarvesterHelper::BasicEnergyHarvesterHelper ( )

Definition at line 28 of file basic-energy-harvester-helper.cc.

References m_basicEnergyHarvester, and ns3::ObjectFactory::SetTypeId().

+ Here is the call graph for this function:

◆ ~BasicEnergyHarvesterHelper()

ns3::BasicEnergyHarvesterHelper::~BasicEnergyHarvesterHelper ( )
override

Definition at line 33 of file basic-energy-harvester-helper.cc.

Member Function Documentation

◆ DoInstall()

Ptr< EnergyHarvester > ns3::BasicEnergyHarvesterHelper::DoInstall ( Ptr< EnergySource source) const
overrideprivatevirtual
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.

Implements ns3::EnergyHarvesterHelper.

Definition at line 44 of file basic-energy-harvester-helper.cc.

References ns3::ObjectFactory::Create(), m_basicEnergyHarvester, and NS_ASSERT.

+ Here is the call graph for this function:

◆ Set()

void ns3::BasicEnergyHarvesterHelper::Set ( std::string  name,
const AttributeValue v 
)
overridevirtual
Parameters
nameName of attribute to set.
vValue of the attribute.

Sets one of the attributes of underlying EnergyHarvester.

Implements ns3::EnergyHarvesterHelper.

Definition at line 38 of file basic-energy-harvester-helper.cc.

References m_basicEnergyHarvester, and ns3::ObjectFactory::Set().

+ Here is the call graph for this function:

Member Data Documentation

◆ m_basicEnergyHarvester

ObjectFactory ns3::BasicEnergyHarvesterHelper::m_basicEnergyHarvester
private

Energy source factory.

Definition at line 48 of file basic-energy-harvester-helper.h.

Referenced by BasicEnergyHarvesterHelper(), DoInstall(), and Set().


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